MedicalVisualization

Open GL Vertex and Fragment Shaders

← Transfer Function Examples | ● | OpenGL GLSL Shader →

Recap: Vertex and fragment shaders are a programmable replacement for steps 2 and 6 of the fixed function pipeline.

Shaders have input registers and output registers (excerpt):

Vertex shader:

  • in: uniform MVP, vertex position, attributes
  • out: transformed vertex position, varying attributes

Fragment shader:

  • in: rasterized fragment position, rasterized varying attributes, uniforms
  • out: final color


← Transfer Function Examples | ● | OpenGL GLSL Shader →

Options: