MemoryTexture

A gdk.texture.Texture representing image data in memory.

Constructors

this
this(int width, int height, gdk.types.MemoryFormat format, glib.bytes.Bytes bytes, size_t stride)

Creates a new texture for a blob of image data.

Inherited Members

From Texture

newForPixbuf
gdk.texture.Texture newForPixbuf(gdkpixbuf.pixbuf.Pixbuf pixbuf)

Creates a new texture object representing the gdkpixbuf.pixbuf.Pixbuf.

newFromBytes
gdk.texture.Texture newFromBytes(glib.bytes.Bytes bytes)

Creates a new texture by loading an image from memory,

newFromFile
gdk.texture.Texture newFromFile(gio.file.File file)

Creates a new texture by loading an image from a file.

newFromFilename
gdk.texture.Texture newFromFilename(string path)

Creates a new texture by loading an image from a file.

newFromResource
gdk.texture.Texture newFromResource(string resourcePath)

Creates a new texture by loading an image from a resource.

getFormat
gdk.types.MemoryFormat getFormat()

Gets the memory format most closely associated with the data of the texture.

getHeight
int getHeight()

Returns the height of the texture, in pixels.

getWidth
int getWidth()

Returns the width of texture, in pixels.

saveToPng
bool saveToPng(string filename)

Store the given texture to the filename as a PNG file.

saveToPngBytes
glib.bytes.Bytes saveToPngBytes()

Store the given texture in memory as a PNG file.

saveToTiff
bool saveToTiff(string filename)

Store the given texture to the filename as a TIFF file.

saveToTiffBytes
glib.bytes.Bytes saveToTiffBytes()

Store the given texture in memory as a TIFF file.