User Submitted Code Samples - Page 8

Z-fail shadows on the GPU (Windows/Linux - SDL/OpenGL - C++)
 

Author: Andreas Jonsson

This sample demonstrates how to render z-fail shadows with the GPU as well as how to take advantage of the two side stencil extension ( GL_EXT_stencil_two_side ). The shaders use OpenGL's GLSL.

 

Soft Z-fail shadows on the GPU (Windows/Linux - SDL/OpenGL - C++)
 

Author: Andreas Jonsson

This sample is basically a new and improved version of the sample above with soft shadow edges.

  • Download (Last Updated: 01/08/07 - Windows)
    Download (Last Updated: 01/08/07 - Linux)

 

Vertex Animation using a VBO (OpenGL - C++)
 

Author: Tomas Dirvanauskas

This sample demonstrates vertex animation using VBOs Three buffers are created for vertices, normals and indices. Vertex and normal buffers are update every frame, index buffer is not. The vertex interpolation is processed by CPU (that's why the Release version is much much faster than Debug)

 

Reflective Bump Mapping (OpenGL - C++)
 

Author: Christoph Kabek

This sample demonstrates how to combine reflective environment mapping and bump (normal) mapping. The sample was inspired by an nVIDIA presentation which can be found here.

 

Per-Pixel Reflective Environment Mapping (OpenGL - C++)
 

Author: Christoph Kabek

This sample shows how to do reflective environment mapping on a per-pixel basis using Cg. To contrast the differences between per-pixel and per-vertex, a per-vertex version of the sample is also available.

  • Download (Per-pixel version - Last Updated: 07/17/07)
  • Download (Per-vertex version - Last Updated: 07/17/07)