| gtkmm 4.18.0
    | 
The Gdk::TextureDownloader is used to download the contents of a Gdk::Texture. More...
#include <gdkmm/texturedownloader.h>
| Public Member Functions | |
| TextureDownloader () | |
| TextureDownloader (GdkTextureDownloader * gobject, bool make_a_copy=true) | |
| TextureDownloader (const TextureDownloader & other) | |
| TextureDownloader & | operator= (const TextureDownloader & other) | 
| TextureDownloader (TextureDownloader && other) noexcept | |
| TextureDownloader & | operator= (TextureDownloader && other) noexcept | 
| ~TextureDownloader () noexcept | |
| void | swap (TextureDownloader & other) noexcept | 
| GdkTextureDownloader * | gobj () | 
| Provides access to the underlying C instance. | |
| const GdkTextureDownloader * | gobj () const | 
| Provides access to the underlying C instance. | |
| GdkTextureDownloader * | gobj_copy () const | 
| Provides access to the underlying C instance. The caller is responsible for freeing it. Use when directly setting fields in structs. | |
| TextureDownloader (const Glib::RefPtr< Texture > & texture) | |
| Creates a new texture downloader for texture. | |
| void | set_texture (const Glib::RefPtr< Texture > & texture) | 
| Changes the texture the downloader will download. | |
| Glib::RefPtr< Texture > | get_texture () | 
| Gets the texture that the downloader will download. | |
| Glib::RefPtr< const Texture > | get_texture () const | 
| Gets the texture that the downloader will download. | |
| void | set_format (MemoryFormat format) | 
| Sets the format the downloader will download. | |
| MemoryFormat | get_format () const | 
| Gets the format that the data will be downloaded in. | |
| Glib::RefPtr< ColorState > | get_color_state () const | 
| Gets the color state that the data will be downloaded in. | |
| void | set_color_state (const Glib::RefPtr< const ColorState > & color_state) | 
| Sets the color state the downloader will convert the data to. | |
| void | download_into (guchar *data, gsize stride) const | 
| Downloads the texture into local memory. | |
| Glib::RefPtr< Glib::Bytes > | download_bytes (gsize & out_stride) const | 
| Downloads the given texture pixels into a Glib::Bytes. | |
| Static Public Member Functions | |
| static GType | get_type () | 
| Get the GType for this class, for use with the underlying GObject type system. | |
| Protected Attributes | |
| GdkTextureDownloader * | gobject_ | 
| Related Symbols | |
| (Note that these are not member symbols.) | |
| void | swap (TextureDownloader & lhs, TextureDownloader & rhs) noexcept | 
| Gdk::TextureDownloader | wrap (GdkTextureDownloader * object, bool take_copy=false) | 
| A Glib::wrap() method for this object. | |
The Gdk::TextureDownloader is used to download the contents of a Gdk::Texture.
It is intended to be created as a short-term object for a single download, but can be used for multipe downloads of different textures or with different settings.
Gdk::TextureDownloader can be used to convert data between different formats. Create a Gdk::Texture for the existing format and then download it in a different format.
| Gdk::TextureDownloader::TextureDownloader | ( | ) | 
| 
 | explicit | 
| Gdk::TextureDownloader::TextureDownloader | ( | const TextureDownloader & | other | ) | 
| 
 | noexcept | 
| 
 | noexcept | 
| 
 | explicit | 
Creates a new texture downloader for texture.
| Glib::RefPtr< Glib::Bytes > Gdk::TextureDownloader::download_bytes | ( | gsize & | out_stride | ) | const | 
Downloads the given texture pixels into a Glib::Bytes. 
The rowstride will be stored in the stride value.
This function will abort if it tries to download a large texture and fails to allocate memory. If you think that may happen, you should handle memory allocation yourself and use download_into() once allocation succeeded.
| out_stride | The stride of the resulting data in bytes. | 
| void Gdk::TextureDownloader::download_into | ( | guchar * | data, | 
| gsize | stride ) const | 
Downloads the texture into local memory.
| data | Pointer to enough memory to be filled with the downloaded data of the texture. | 
| stride | Rowstride in bytes. | 
| Glib::RefPtr< ColorState > Gdk::TextureDownloader::get_color_state | ( | ) | const | 
Gets the color state that the data will be downloaded in.
| MemoryFormat Gdk::TextureDownloader::get_format | ( | ) | const | 
Gets the format that the data will be downloaded in.
| Glib::RefPtr< Texture > Gdk::TextureDownloader::get_texture | ( | ) | 
Gets the texture that the downloader will download.
| Glib::RefPtr< const Texture > Gdk::TextureDownloader::get_texture | ( | ) | const | 
Gets the texture that the downloader will download.
| 
 | static | 
Get the GType for this class, for use with the underlying GObject type system.
| 
 | inline | 
Provides access to the underlying C instance.
| 
 | inline | 
Provides access to the underlying C instance.
| GdkTextureDownloader * Gdk::TextureDownloader::gobj_copy | ( | ) | const | 
Provides access to the underlying C instance. The caller is responsible for freeing it. Use when directly setting fields in structs.
| TextureDownloader & Gdk::TextureDownloader::operator= | ( | const TextureDownloader & | other | ) | 
| 
 | noexcept | 
| void Gdk::TextureDownloader::set_color_state | ( | const Glib::RefPtr< const ColorState > & | color_state | ) | 
Sets the color state the downloader will convert the data to.
By default, the sRGB colorstate returned by color_state_get_srgb() is used.
| color_state | The color state to use. | 
| void Gdk::TextureDownloader::set_format | ( | MemoryFormat | format | ) | 
Sets the format the downloader will download.
By default, GDK_MEMORY_DEFAULT is set.
| format | The format to use. | 
| void Gdk::TextureDownloader::set_texture | ( | const Glib::RefPtr< Texture > & | texture | ) | 
Changes the texture the downloader will download.
| texture | The new texture to download. | 
| 
 | noexcept | 
| 
 | 
| lhs | The left-hand side | 
| rhs | The right-hand side | 
| 
 | 
A Glib::wrap() method for this object.
| object | The C instance. | 
| take_copy | False if the result should take ownership of the C instance. True if it should take a new copy or ref. | 
| 
 | protected |