Inc
16th August 2005, 13:31
Question a):
Lets assume I do load rgb data into memory using dgdecode.dll's getRGBFrame() at a memorypointer *rgb24.
Now how is the order of the RGB data in memory:
(RGB24 Like ...
RGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGB ...... etc.
I do know getRGBFrame results in rgb24 data, but just to know how generally rgb32 data is stored )
RGB32 like ...
RGBARGBARGBARGBARGBARGBARGBARGBARGBA ..... etc.
And for YUV via dgdecode.dll's getFrame()
YUVYUVYUVYUVYUVYUVYUVYUVYUVYUVYUVYUV .... etc.
is that right? I think not due 4:2:0 12 Bit allocation?
Question b)
If I do use the VFW API AviFileGetFrame() is there generally a RGB result, no matter if even the Frame in the avi is YUV ?
Would the allocation of Pixeldata using AviFileGetFrame() also be stored as YUV Values in Memory like ...
B = BITMAPINFOHEADER data and its size
BYUVBYUVBYUVBYUVBYUVBYUV .... etc.
?
Thanks for your help
Purpose of all this is that I want to build an autocrop part in a video applikation using the way of directly peeking the memory instead of GetPixe() via API out of a generated Bitmap using SetDIBits() ... I think the peek() approach would be much faster.
Also if I can handle it, I would like to build a histogram window using the peek function on the image data at a given Memorypointer.
Lets assume I do load rgb data into memory using dgdecode.dll's getRGBFrame() at a memorypointer *rgb24.
Now how is the order of the RGB data in memory:
(RGB24 Like ...
RGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGBRGB ...... etc.
I do know getRGBFrame results in rgb24 data, but just to know how generally rgb32 data is stored )
RGB32 like ...
RGBARGBARGBARGBARGBARGBARGBARGBARGBA ..... etc.
And for YUV via dgdecode.dll's getFrame()
YUVYUVYUVYUVYUVYUVYUVYUVYUVYUVYUVYUV .... etc.
is that right? I think not due 4:2:0 12 Bit allocation?
Question b)
If I do use the VFW API AviFileGetFrame() is there generally a RGB result, no matter if even the Frame in the avi is YUV ?
Would the allocation of Pixeldata using AviFileGetFrame() also be stored as YUV Values in Memory like ...
B = BITMAPINFOHEADER data and its size
BYUVBYUVBYUVBYUVBYUVBYUV .... etc.
?
Thanks for your help
Purpose of all this is that I want to build an autocrop part in a video applikation using the way of directly peeking the memory instead of GetPixe() via API out of a generated Bitmap using SetDIBits() ... I think the peek() approach would be much faster.
Also if I can handle it, I would like to build a histogram window using the peek function on the image data at a given Memorypointer.