Skip to content

Instantly share code, notes, and snippets.

@rozgo
Created August 15, 2011 01:54
Show Gist options
  • Save rozgo/1145591 to your computer and use it in GitHub Desktop.
Save rozgo/1145591 to your computer and use it in GitHub Desktop.
view matrix reminders
for a modelview matrix is:
m0 m4 m8 m12
m1 m5 m9 m13
m2 m6 m10 m14
m3 m7 m11 m15
then:
(m0,m1,m2): X-Model in View coord.
(m4,m5,m6): Y-Model in View coord.
(m8,m9,m10): Z-Model in View coord.
(m0,m4,m8): X-View in Model coord.
(m1,m5,m9): Y-View in Model coord.
(m2,m6,m10): Z-View in Model coord.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment