Computergrafik

GLSL Operationen

← GLSL Datentypen | ● | GLSL Parameter →

Die Vektor Addition und Multiplikation mit + und * erfolgt komponentenweise.

Matrix zu Matrix and Matrix zu Vektor Operationen (+ und *) sind ebenfalls unterstützt.

Das Skalarprodukt und das Kreuzprodukt werden durch die Funktionen dot() bzw. cross() unterstützt.

Weiterhin gibt es eine Reihe von nützlichen Funktionen z.B.:

  • normalize(vec4 v)
  • clamp(vec4 v, double min, double max)


← GLSL Datentypen | ● | GLSL Parameter →

Options: