4.51.2.4.44. ogRGB() | Table of Contents | 4.51.2.4.46. ogSavePal() |
function ogRGBA(red, green, blue, alpha:uInt8):uInt32;Remarks:
For all high-colour and true-colour surface, this will pack the pixel based on the pixel format of the surface. Different surface can have different RGB orderings and sizes, so it is advised one use this function to generate colour values for other functions. For 8BPP buffers, this function will return the closest colour to the requested RGB value using an imperfect colour matching algorithm.
A totally opaque pixel has an alpha level of 255.
A totally transparent pixel has an alpha level of 0.
How the pixel is rendered to the surface depends on the drawing function
and whether or not blending is enabled.
RGB channels are at most 8-bits wide. This will be changed in a future revision. Will only return a packed pixel for surface with a bitdepth of 8, 15, 16, 24, and 32.
See also:4.51.2.4.44. ogRGB() | Table of Contents | 4.51.2.4.46. ogSavePal() |