Skip to content

Std graphics pixmap

std:std.graphics.Pixmap

Class Pixmap Extends Resource#

Pixmaps allow you to store and manipulate rectangular blocks of pixel data.

A pixmap contains a block of memory used to store a rectangular array of pixels.

Constructors
New Creates a new pixmap.
Properties
Data The raw pixmap data. (read only)
Depth The pixmap depth. (read only)
FilePath Image filepath.
Format The pixmap format. (read only)
HasAlpha True if pixmap format includes alpha. (read only)
Height The pixmap height. (read only)
Pitch The pixmap pitch. (read only)
Size The width and height of the pixmap. (read only)
Width The pixmap width. (read only)
Methods
Clear Clears the pixmap to a given color.
ClearARGB Clears the pixmap to an ARGB color.
Convert Converts the pixmap to a different format.
Copy Creates a copy of the pixmap.
FlipY Flips the pixmap on the Y axis.
GetPixel Gets the color of a pixel.
GetPixelARGB Gets the ARGB color of a pixel.
MipHalve Halves the pixmap for mipmapping
Paste Paste a pixmap to the pixmap.
PixelPtr Gets a pointer to a pixel in the pixmap.
PremultiplyAlpha Premultiply pixmap r,g,b components by alpha.
Save Saves the pixmap to a file.
SetPixel Sets a pixel to a color.
SetPixelARGB Sets a pixel to an ARGB color.
Window Returns a rectangular window into the pixmap.
Functions
Load Loads a pixmap from a file.
Protected methods
OnDiscard
OnFinalize