I'm trying to read a DPX file using the example wind32 C++ program using 3.11
It works for a 10 bit RGB file, but when I try the same thing with an RGBA 8 bit, the colors are screwed up
load_params.Flags |= GFL_LOAD_SKIP_ALPHA | GFL_FORCE_COLOR_MODEL;
load_params.Origin = GFL_BOTTOM_LEFT;
load_params.ColorModel = GFL_BGR;
I looked at the data and discovered that there was no Green channel. So I did
load_params.Origin = GFL_BOTTOM_LEFT;
load_params.ColorModel = GFL_BGR;
Should this give me BGRA, but when I looked the data, the 2an channel was the alpha channel, BAGR,
The picture displays fine if I use this format.
What do I need to do in the load-params to get it to read correctly?
Thank you
Here is the relevant header for the DPX file
First 4 bytes of file: SDPX
ulMagicNumber: 1396985944
caVersionNumber: "V1.0"
caDescription: "IMAGE DESCRIPTION DATA "
fHighDataQuantity: 2.0469999
fLowDataQuantity: 0.00000000
ucBitSize: 8
ucColorimetricSpec: 2
ucDescriptor: 51 (R,G,B,alpha)
ucTransferCharacteristic: 2
ulDataSign: 0
ulEndOfImagePadding: 0
ulEndOfLinePadding: 0
ulHighDataValue: 255
ulLowDataValue: 0
ulOffsetToData: 8192
usEncoding: 0
usPacking: 0
Problems reading a DPX file
Moderators: XnTriq, helmut, xnview
-
- Author of XnView
- Posts: 44325
- Joined: Mon Oct 13, 2003 7:31 am
- Location: France
Re: Problems reading a DPX file
There is many problem with DPX encoding, some software write BGR, and some others RGB.
Could you send me the DPX?
Could you send me the DPX?
Pierre.
-
- Posts: 2
- Joined: Mon Feb 15, 2010 10:23 pm
Re: Problems reading a DPX file
I sent the file to you at webmaster@<-- removed* -->. It is RGBA but should show up as a grayscale image. The alpha is all zeros.
Thanks
Thanks
- <-- * E-mail address removed by moderator (see “Rules and Guidelines”) -->