Wednesday, March 07, 2012 5:01 PM
Some code I've written and tested under Win7 fails under XP SP3. The WIC Explorer sample fails in the same way.
- CreateComponentInfo for a WICPixelFormatGUID fails with WINCODEC_ERR_COMPONENTNOTFOUND
- CreateComponentEnumerator(WICPixelFormat, ...) succeeds, but the resultant enumerator is empty.
Apart from this, the WIC Explorer sample mostly functions in that it will read images - although write is not possible since pixel format selection is unavailable.
- Are these known issues for XP SP3?
- Is there another way to find the properties of a pixel format?
The "WIC in Windows 7" post suggests that IPixelFormatInfo2 was added in Win7 and was later made available in Vista/2008. Is it also available under XP SP3? (On the XP SP3 machine I'm using, IPixelFormatInfo is registered but IPixelFormatInfo2 is not).
- Is there a way to install an update on XP that provides IPixelFormatInfo2?
- Is there another way to find the numeric representation property of a pixel format?
- Are there other parts of the documented features of WIC that are unavailable under XP SP3?
- Edited by PhilAtkin Wednesday, March 07, 2012 5:19 PM
Thursday, March 08, 2012 10:47 AM
WIC was greatly enhanced in Vista SP1, SP2 and then even more with Win7 and none of the additional features and fixes were back-ported to XP, which still has a version dating from 2006 I guess. There is no way to use a native pixel format introduced in later versions on the older XP version, and WIC will likely never be serviced there because XP mainstream support has ended 3 years ago.
Depending on what you are trying to do you may still be able to get away with some pre or post processing, like swapping the channels yourself if what you need is some RGB format and WIC on XP only has BGR, or some similarly simple problem. WIC is also extensible and there is probably a way to register new pixel formats, but I’m not sure is that part was documented at all?