Using Quartz to render OpenGL textures, with alpha?
Hi,
I am trying to use Quartz drawing functions to render into a CGContext, then create textures from this context to use for texture mapping in OpenGL. My current implementation mostly works, but I'm hitting a problem with alpha.
I use CGBitmapContextCreate() to create a context from scratch with an RGB color space. It seems that this function only supports premultiplied alpha, so there's no way to draw pixels with real alpha channel info to one of these contexts.
Is my understanding of this correct? If so, this approach won't work for my app so I need to figure out a different way to get a CG context, one that will allow me to preserve full alpha channel info. Any ideas?
Thanks
|