x
y
x
y
x
y
x
y
Und die
Translation?
Bild: A. Nischwitz
Die Reihenfolge der Transformationen ist wichtig!
Bild: T. Thormählen
Bild: D. Jimenez
Bild: By SharkD (CC BY-SA 4.0), https://commons.wikimedia.org/w/index.php?curid=58479044, altered by small visibility changes
Bild: G. Mansfield
Bild: T. Thormählen (adaptiert)
\( \hat{\mathbf{P}} \)
\( \hat{\mathbf{P}} \)
→ siehe Strahlensatz:
4x4-Matrix darstellen:Hinweis: In OpenGL zeigt Kamera in negative z-Richtung, daher \( -p_z \)
Bild: T. Thormählen
Bild: A. Nischwitz
void gluLookAt(
// Position der Kamera:
double eyeX, double eyeY, double eyeZ,
// Betrachtungspunkt (Look/Center):
double centerX, double centerY, double centerZ,
// Up-Vektor (Oben)
double upX, double upY, double upZ
);Eye: Wo befindet sich der Betrachter?
Look: Wohin schaut der Betrachter?
Up: Wo ist "Oben"? (meist \( (0, 1, 0) \))
Live
coding
Formen von Transformationen:
Bild: T. Thormählen