|
|
|
|
| |
Volume Texturing on the Radeon®
|
|
|
The RadeonVolumeTexture uses EXT_texture3D to demonstrate volume texturing in OpenGL®. For more on this and other uses of 3D textures, see our 3D Texture Mapping Tutorial. This sample shows a set of objects drawn with a procedurally generated texture. It uses both a marble texture and a color cube texture. Additionally, the app uses the stencil buffer and a single user clip plane to perform a simple CSG operation. The notable benefit of using 3D textures in this app is that the objects always have a consistent mapping even though they are being sliced. This sort of technique can easily be used for the texturing to arbitrary procedural geometry.
Marble Texture Generation
The marble texture is generated by a relatively well-known algorithm with Perlin noise. The code contained here is loosly based on the Blue Marble shader from The RenderMan Companion by Steve Upstill. The noise functions are the original ones used by Ken Perlin of NYU and are based on his noise code.
| |
|
|
|
Figure 1 - CSG Operation
|
Figure 2 - Classic Marble
Vase
|
| |
|
- RadeonVolumeTexture Controls
-
- T - Toggle between the marble and color cube
textures
- + - Cycle forward through the list of objects
- - - Cycle backward through the list of objects
- [SPACE] - Switch control modes
- [ESC] - Quit
Downloads
Note: The source code and media should be unzipped into the following recommended directory structure to ensure you can easily compile and run the executable.
Radeonxxxxxx.zip -> x:\atiddk\OpenGLmedia.zip -> x:\atiddk\mediaraw.zip -> x:\atiddk\media RadeonVolumeTexture.zip
media.zip
Back to Samples Page
| |
| |
|
| |
 |
|
|
|