Back to class index

Class Bitmap

Summary

Allows manipulating pixels of 2D surfaces, regardless of their actual format.

Member Reference

BitmapAllows manipulating pixels of 2D surfaces, regardless of their actual format.
ColorStructDefines the format of the surface.
color_tThe type of a single pixel.
channel_tThe type of a single channel.
ctor (+2 overloads)
address(x,y)[const]Returns a pointer to the pixel at location (x,y).
PutPixel(x,y,color)Plots a pixel to (x,y), assumes data is ARGB8888.
GetPixel(x,y)[const]Returns the pixel at (x,y), assumes data is 32-bit.
Clear(color)Clears the whole bitmap, assumes data is 32-bit.
Width()[const]Returns width of the image, in pixels.
Height()[const]Returns height of the image, in pixels.
Pitch()[const]Returns the number of bytes between two scanlines. (Not necessarily width * bytesPerPixel).
Circle(x,y,radius,color)Draws a hollow circle.
FillCircle(x,y,radius,color)Draws a filled circle.
FillRectangle(x1,y1,x2,y2,color)Draws a filled rectangle.
Rectangle(x1,y1,x2,y2,color)Draws a hollow rectangle.
Line(...)Draws a line.
Back to class index