HLSL Geometry Shader crash course

Started by
1 comment, last by winsrp 12 years ago
Does anyone know where to find some HLSL GS examples, tutorials or such? been all over the web and I can't seem to find even a code example!!..
Advertisement
There are a few samples in the SDK that use the geometry shader.

Tutorial 13: Geometry Shaders - shows basic usage of the geometry shader
SoftPaticles - shows what is probably the most common usage of the geometry shader, which is expanding a point into a billboarded quad
ParticlesGS - shows how to use the GS to stream out particle data, so that you can run a simulation on the GPU (better done with compute shaders)
MotionBlur10 - uses the geometry shader to extrude triangles along their velocity to simulate motion blur
CubeMapGS - uses the geometry shader to replicate a mesh to the 6 faces of a cube map, in order to render reflections in a single pass
PipesGS - shows a really weird usage of geometry shaders to generate geometry on the fly
ShadowVolume10 - uses the GS to extrude stencil shadow volumes without the CPU
Skinning10 - uses the GS to stream out skinned vertices (useful if you're going to render skinned meshes for multiple shadow-casting lights or for reflections)
SubD10 - a really advanced sample that uses the GS to implement tessellation (definitely don't want to do this if you can use the tessellation support in DX11)

Nvidia also has some samples in their SDK:

Lighting - renders a lighting effect
Rain - renders rain using the GS to generate quads from points for particles
Fur - Shells and Fins - uses the GS to generate fins at silhouettes for a fur effect
Cloth Simulation - uses the GS to stream out data for a cloth simulation run on the GPU
GPUBlendshapes - uses the GS to stream out accumulated morph mesh data to apply an arbitrary number of morph targets
MetaBalls - uses the GS to perform isosurface tessellation
well, I just need to make from one point a cube... nothing too advanced.. but thanks for the info, ... I'll give them a try.

This topic is closed to new replies.

Advertisement