Jump to content
  • Advertisement
Sign in to follow this  

HLSL Geometry Shader crash course

This topic is 2246 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

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!!..

Share this post


Link to post
Share on other sites
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

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!