t2getp

Syntax

int t2getp(int x, int y)

Arguments

x, y
Image coordinates

Return

Returns the pixel value at the specified image coordinates

Description

This function lets you read a whole pixel from the second tile buffer. Unlike t2get the returned value includes the values of all color channels (including the transparency channel if one is available) of the pixel. Using t2getp instead of t2get takes only approximately half as much time. To decode the individual color values from the returned pixel value you have to use the Rval, Gval, Bval and Aval functions. Currently only works with 8 bit images.

Example

Also see

srcp, pgetp, psetp, tgetp, tsetp, t2setp, Rval, Gval, Bval and Aval

Comments

Everyone can add his comments about his experiences with this function here. Tips for using it are welcome, too.