next up previous contents
Next: 15.3.3.1 Alpha Buffer Approach Up: 15.3 Gradual Cutaway Views Previous: 15.3.2 Refinements

15.3.3 Rendering a Surface Textured Shell

The steps above assume an untextured object shell. If the shell itself has a surface texture, things get more involved. The preference would be to apply both the 2D surface texture and the 1D transparency texture ramp simultaneously. In order to blend two textures together, use a multipass method. The basic idea is to separate the blend function glBlendFuncGL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA) into two separate steps. There are now three objects to consider; internal components of the object, the shell of the object textured with a surface texture, and the shell of the object textured with the 1D alpha texture. The alpha textured shell is used to adjust the transparency of the other two objects separately.

Two approaches suggest themselves, based on your hardware's capabilities. If your system supports an alpha buffer, the approach is only a little more complicated. If you don't, you can do it with two buffers.



 

David Blythe
1999-08-06