|
From: James W. <ja...@fr...> - 2007-05-12 01:50:23
|
In parallel to this thread, I have been reading up on alpha compositing and premultiplied alpha, and I can see that it is reasonable to prefer premultiplied alpha. It's still not completely clear how QuickDraw 3D handled alpha, but it does appear that the Interactive Renderer in Quesa assumes premultiplied alpha, and probably has always done so. Here's what I've done: * Changed the OpenGL renderer back to assuming premultiplied alpha. * Added documentation about premultiplied alpha to TQ3PixelType in Quesa.h. * Defined a new object property, kQ3RendererPropertyConvertToPremultipliedAlpha, which can be applied to the renderer object. This causes a conversion to premultiplied alpha when the texture is loaded into OpenGL, and works on both Interactive and OpenGL renderers. -- James W. Walker, Innoventive Software LLC <http://www.frameforge3d.com/> |