BradLarson/GPUImage — pull request #23 by chwilliam (2012-03-09 21:40:38+00:00)
Title: Image Alpha Support

I've been using Core Image to desaturate some graphics. I was trying to use GPUImage instead of CI b/c CoreImage was still a little too slow for our needs. There ended up being three issues:

1. Use of malloc instead of calloc doesn't clear memory in the simulator, so there's memory junk in transparent areas
2. Your CGImage initialization doesn't specify an alpha component
3. Most shaders set the alpha value of gl_FragColor to 1.0 by default

I went through and fixed a good number of the shaders, and I confirmed the ones that I touch work properly with alpha images.

Thanks for the great foundation. It's really nice being able to just write shaders and use them as filters.