On 08/12/2013 at 23:21, xxxxxxxx wrote:
User Information:
Cinema 4D Version: R15
Platform: Windows ;
Language(s) :
---------
I have a HDR 32 bit texture layer and now I want to read the color values.
For normal 8 bit textures this is not a problem, but how to get the 32 bit color values.
Here is my attempt:
Float buffer[3]; //one pixel is 1 float (4 bytes) * 3 (RGB) = 3 floats
//get one pixel to test
pLayerBmp->GetPixelCnt(0,0,1,(UChar* )buffer,COLORMODE_RGBf, PIXELCNT_0);
GePrint("Before pixel 0,0: " + String::FloatToString(buffer[0]) \+ " - " +
String::FloatToString(buffer[1]) + " - " +
String::FloatToString(buffer[2]));