Portal:OpenGL Shading Language/Geometry Shader

From OpenGL Wiki
< Portal:OpenGL Shading Language
Revision as of 14:59, 12 April 2015 by AlfonsesRenamerBot (talk | contribs) (Bot: Updating section links to use redirects.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

The Geometry Shader is the shader stage just before Vertex Post-Processing. It takes a Primitive as input and outputs zero or more primitives. Geometry Shaders are used to do setup work for Transform Feedback operations, as well as tag primitives as being rasterized to specific layers in the Framebuffer Object.

Though Geometry Shaders can be used to implement a form of tessellation, you are advised to avoid using them for this purpose. On hardware that lacks Tessellation support, GS's will be quite slow at it. And on hardware with proper Tessellation support, you should just use that.