Export (0) Print
Expand All

CImage::GetPixelAddress 

Retrieves the exact address of a pixel.


void* GetPixelAddress(
   int x,
   int y 
) throw( );

Parameters

x

The x-coordinate of the pixel.

y

The y-coordinate of the pixel.

The address is determined according to the coordinates of a pixel, the pitch of the bitmap, and the bits per pixel.

For formats that have less than 8 bits per pixel, this method returns the address of the byte containing the pixel. For example, if your image format has 4 bits per pixel, GetPixelAddress returns the address of the first pixel in the byte, and you must calculate for 2 pixels per byte.

NoteNote

This method supports only DIB section bitmaps.

Reference

CImage Class

Other Resources

CImage Members

Community Additions

ADD
Show:
© 2015 Microsoft