http://bugs.winehq.org/show_bug.cgi?id=4935
--- Comment #21 from Roderick Colenbrander thunderbird2k@gmx.net 2007-08-20 10:18:03 --- I have debugged the program but the results aren't positive for now. At the time we used totally different pixelformat code, there's not much left of it, so I can't compare that with the current situation.
When you want to use OpenGL in your program you need to select a pixelformat which describes the number of color bits, whether you want double buffering and more.
The traditional way to select a pixelformat is by using ChoosePixelFormat. You pass some specifications to it and it selects something. The problem is that this function can return pixelformats which don't meet your specifications. (Why this is a different story)
For this reason some programs implement their 'own' ChoosePixelFormat by walking through all available pixelformats. This is what the IKEA program is doing using DescribePixelFormat.
First of all it wants a single buffered pixelformat with GDI support (PFD_DOUBLEBUFFER | PFD_SUPPORT_GDI). Right now we don't offer any single buffering formats but this is fixable though tricky.
The most problematic thing it does is: cColorBits = GetDeviceCaps(BITSPIXEL) | GetDeviceCaps(PLANES)
In case of GLX cColorBits corresponds to GLX_BUFFER_SIZE which is 32 while BITSPIXEL is 24.. That's the main problem.
Wine's GetDeviceCaps should get fixed.