Multiple Output Streams

Multiple streams of vertices can be declared as outputs in the geometry shader. Output streams are declared using the stream layout qualifier. This layout qualifier may be applied globally, to an interface block, or to a single output declaration. Each stream is numbered, starting from zero and an implementation defined maximum number of streams can be declared. That maximum can be found by calling glGetIntegerv() with the parameter GL_MAX_VERTEX_STREAMS, and all OpenGL implementations are required to support at least four geometry shader output streams. When the stream number is given at global scope, all subsequently declared geometry shader outputs become members of that stream until another output stream layout qualifier ...

Get OpenGL Programming Guide: The Official Guide to Learning OpenGL, Version 4.3, Eighth Edition now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.