Inventor/oivShaderVariables.h File Reference

oiv_include <Inventor/oivShaderStages.h> More...

Go to the source code of this file.

Functions

float OivFogFragCoord ()
void OivInitVertexData ()
void OivSetFrontColor (in vec4 color)
void OivSetBackColor (in vec4 color)
void OivSetTexCoord (in int unit, in vec4 coord)
void OivSetFogFragCoord (in float coord)

Detailed Description

oiv_include <Inventor/oivShaderStages.h>

This file contains fonction to acces built-in GLSL varyings

Definition in file oivShaderVariables.h.


Function Documentation

float OivFogFragCoord (  ) 

IN.

Get the fog frag coord of the input vertex or fragment. Available in:

  • Vertex Shader
  • Fragment Shader
void OivInitVertexData (  ) 

OUT.

Some GPU require vertex data to be initialized even if you don't use them. If you encounter message error such as: "The fragment shader uses varying _I;OIV_VERTEX_DATA;xxx, but previous shader does not write to it.", you should call this method at the beginning of your vertex shader main.

void OivSetBackColor ( in vec4  color  ) 

Set the back color of the output vertex for the next shader stage.

Available in:

  • Vertex Shader
  • Tessellation Control Shader
  • Tessellation Evaluation Shader
  • Geometry Shader
void OivSetFogFragCoord ( in float  coord  ) 

Set the fog frag coord of the output vertex for the next shader stage.

Available in:

  • Vertex Shader
  • Tessellation Control Shader
  • Tessellation Evaluation Shader
  • Geometry Shader
void OivSetFrontColor ( in vec4  color  ) 

Set the front color of the output vertex for the next shader stage.

Available in:

  • Vertex Shader
  • Tessellation Control Shader
  • Tessellation Evaluation Shader
  • Geometry Shader
void OivSetTexCoord ( in int  unit,
in vec4  coord 
)

Set the texture coordinates of the output vertex for the next shader stage.

Available in:

  • Vertex Shader
  • Tessellation Control Shader
  • Tessellation Evaluation Shader
  • Geometry Shader

Open Inventor Toolkit reference manual, generated on 12 Feb 2024
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/