iPhone GLES 2 Orthogonal frame - Printable Version
+- iDevGames Forums (http://www.idevgames.com/forums)
+-- Forum: Development Zone (/forum-3.html)
+--- Forum: iPhone, iPad & iPod Game Development (/forum-11.html)
+--- Thread: iPhone GLES 2 Orthogonal frame (/thread-149.html)
iPhone GLES 2 Orthogonal frame - jeckil - Apr 15, 2010 12:47 PM
Hey there is there a way to forze the othogonal frame to more easily to manage coordinates?
right now i have it (more like opengl has it) default as 2d rendering at -1 1 and -1 1 in xy how can I change it to more 2d friend 0 1 - 0 1 xy?
I remember doing that using glotho back in the day but how does it work now that glortho does not exist?
Thanks In Advance!
iPhone GLES 2 Orthogonal frame - jeckil - Apr 15, 2010 01:36 PM
I got it
I had to multiply by a matrix inside the shader in order to get the correct coordinates
in this case
iPhone GLES 2 Orthogonal frame - dazza - Apr 16, 2010 08:33 AM
hi, this page describes the glOrtho function and the matrix it generates. You are better off loading that matrix into your shader (once per frame) rather then offsetting the default for every vertex that comes through the shader (if I understand your post correctly).
hope that helps.
 - http://www.cs.utk.edu/~vose/c-stuff/opengl/glOrtho.html