Gdk.MemoryTexture¶
class — extends Texture, Paintable, Gio.Icon, Gio.LoadableIcon
A GdkTexture representing image data in memory.
Constructors¶
new¶
@classmethod
def new(cls, width: int, height: int, format: MemoryFormat | int, bytes: bytes, stride: int) -> MemoryTexture
Creates a new texture for a blob of image data.
The GBytes must contain stride × height pixels
in the given format.
Parameters:
width— the width of the textureheight— the height of the textureformat— the format of the databytes— theGBytescontaining the pixel datastride— rowstride for the data