View Full Version : How to use transparency?

10-13-2011, 09:19 AM

This is a basic question: I just want to enable the transparency of the 3D object with RGBA colors and not texture. I used blending and followed Learning WebGL Lessons 8 http://learningwebgl.com/blog/?p=859

but found that I can't make it work with RGBA color. Some objects that have alpha value as 1 and are in front of others, are still seem as transparent objects.

I think since I disabled depth testing, I need to draw the objects in the order that how they cover the others. But is there anyway I can simply draw them without considering the order and just show the objects with alpha value less than 1 as transparent? Thank you very much!

03-02-2012, 05:48 AM
This is a very complex question, actually.
The question is co complex, I personally don't want to handle transparency in my engine.

Anyway, you could try the Dual Deep Peeling method.