BRL.Pixmap: | Functions | Types | Modinfo | Source |
Function ConvertPixmap:TPixmap( pixmap:TPixmap,format ) | |
Returns | A new pixmap object with the specified pixel format. |
Description | Convert pixel format of a pixmap. |
Information | See CreatePixmap for valid pixmap formats. |
Function CopyPixmap:TPixmap( pixmap:TPixmap ) | |
Returns | A new pixmap object. |
Description | Copy a pixmap. |
Function CreatePixmap:TPixmap( width,height,format,align_bytes=4 ) | |||||||||||||||
Returns | A new pixmap object of the specified width and height. | ||||||||||||||
Description | Create a pixmap. | ||||||||||||||
Information | format should be one of the following:
|
Function CreateStaticPixmap:TPixmap( pixels:Byte Ptr,width,height,pitch,format ) | |
Returns | A new pixmap object that references an existing block of memory. |
Description | Create a pixmap with existing pixel data. |
Information | The memory referenced by a static pixmap is not released when the pixmap is deleted. See CreatePixmap for valid pixmap formats. |
Function LoadPixmap:TPixmap( url:Object ) | |
Returns | A pixmap object. |
Description | Load a pixmap. |
Function MaskPixmap:TPixmap( pixmap:TPixmap,mask_red,mask_green,mask_blue ) | |
Returns | A new pixmap object. |
Description | Mask a pixmap. |
Information | MaskPixmap builds a new pixmap with alpha components set to '0' wherever the pixel colors in the original pixmap match mask_red, mask_green and mask_blue. mask_red, mask_green and mask_blue should be in the range 0 to 255. |
Function PixmapFormat( pixmap:TPixmap ) | |||||||||||||||
Returns | The format of the pixels stored in pixmap. | ||||||||||||||
Description | Get pixmap format. | ||||||||||||||
Information | The returned value will be one of:
|
Function PixmapHeight( pixmap:TPixmap ) | |
Returns | The height, in pixels, of pixmap. |
Description | Get pixmap width. |
Function PixmapPitch( pixmap:TPixmap ) | |
Returns | The pitch, in bytes, of pixmap. |
Description | Get pixmap pitch. |
Information | Pitch refers to the difference, in bytes, between the start of one row of pixels and the start of the next row. |
Function PixmapPixelPtr:Byte Ptr( pixmap:TPixmap,x=0,y=0 ) | |
Returns | A byte pointer to the pixels stored in pixmap. |
Description | Get pixmap pixels. |
Function PixmapWidth( pixmap:TPixmap ) | |
Returns | The width, in pixels, of pixmap. |
Description | Get pixmap width. |
Function PixmapWindow:TPixmap( pixmap:TPixmap,x,y,width,height ) | |
Returns | A new pixmap object. |
Description | Create a pixmap window. |
Information | PixmapWindow creates a 'virtual' window into pixmap. |
Function ReadPixel( pixmap:TPixmap,x,y ) | |||||||||
Returns | A 32 bit pixel value. | ||||||||
Description | Read a pixel from a pixmap. | ||||||||
Information | The returned 32 bit value contains the following components:
|
Function ResizePixmap:TPixmap( pixmap:TPixmap,width,height ) | |
Returns | A new pixmap object of the specified width and height. |
Description | Resize a pixmap. |
Function WritePixel( pixmap:TPixmap,x,y,argb ) | |||||||||
Description | Write a pixel to a pixmap. | ||||||||
Information | The 32 bit argb value contains the following components:
|
Function XFlipPixmap:TPixmap( pixmap:TPixmap ) | |
Returns | A new pixmap object. |
Description | Flip a pixmap horizontally. |
Function YFlipPixmap:TPixmap( pixmap:TPixmap ) | |
Returns | A new pixmap object. |
Description | Flip a pixmap vertically. |
Type TPixmap Extends TData | |
Description | The Pixmap type. |
Field capacity | |
Description | The capacity, in bytes, of the pixmap, or -1 for a static pixmap. |
Field format | |
Description | The pixel format of the pixmap. |
Field height | |
Description | The height, in pixels, of the pixmap. |
Field pitch | |
Description | The pitch, in bytes, of the pixmap. |
Field pixels:Byte Ptr | |
Description | A byte pointer to the pixmap's pixels. |
Field width | |
Description | The width, in pixels, of the pixmap. |
Method Convert:TPixmap( format ) | |
Returns | A new TPixmap object in the specified format. |
Description | Convert a pixmap. |
Method Copy:TPixmap() | |
Returns | A new TPixmap object. |
Description | Duplicate a pixmap. |
Method Paste( source:TPixmap,x,y ) | |
Description | Paste a pixmap. |
Method PixelPtr:Byte Ptr( x,y ) | |
Returns | A byte pointer to the pixel at coordinates x, y. |
Description | Get memory address of a pixel. |
Method ReadPixel( x,y ) | |
Returns | The pixel at the specified coordinates packed into an integer. |
Description | Read a pixel from a pixmap. |
Method Window:TPixmap( x,y,width,height ) | |
Returns | A static pixmap that references the specified rectangle. |
Description | Create a virtual window into a pixmap. |
Method WritePixel( x,y,argb ) | |
Description | Write a pixel to a pixmap. |
Function Create:TPixmap( width,height,format,align=4 ) | |
Returns | A new TPixmap object. |
Description | Create a pixmap. |
Function CreateStatic:TPixmap( pixels:Byte Ptr,width,height,pitch,format ) | |
Returns | A new TPixmap object. |
Description | Create a static pixmap. |
Type TPixmapLoader | |
Description | Abstract base type for pixmap loaders. |
Information | To create a new pixmap loader, you should extend TPixmapLoader and implement the LoadPixmap method. To install your pixmap loader, simply create an instance of it using New. |
Method LoadPixmap:TPixmap( stream:TStream ) Abstract | |
Description | Load a pixmap. |
Information | This method must be implemented by extending types. |
Version | 1.04 |
---|---|
Author | Mark Sibly |
License | Blitz Shared Source Code |
Copyright | Blitz Research Ltd |
Modserver | BRL |
History | Removed AddPixmapLoader function |