Why is this like this? (ipad/desktop) difference,
Members - Reputation: 300
Posted 21 June 2012 - 10:15 PM
On the desktop I do the usual projection matrix using my favourite math library, but on the ipad only the top function would work. I still cant quite understand why, I obtained the iPad value through trial and error. Those values are left, right, bottom, top.
GLGXMatrixOrthoOffCenter2D(&Ortho, 0.5, 1.0, 0.5, 1.0); //iPad ortho matrix
GLGXMatrixOrthoOffCenter2D(&Ortho, -1.0, 1.0, -1.0, 1.0); //Desktop ortho matrix
Crossbones+ - Reputation: 24090
Posted 22 June 2012 - 08:06 AM
It is also possible that the library you are using changes for each platform.
If you can verify this is not the case, then you should start looking elsewhere for differences between the environments.
Although if this is just for post-processing, it would be more efficient to simply make a quad with vertices at [-1, -1], [1, -1], [-1, 1], and [1, 1] and perform no matrix transform on them. Not only is it faster (avoids matrix multiply, which does nothing but put the vertices into those positions anyway), it also guarantees the same result on all platforms.
My Art: http://l-spiro.deviantart.com/gallery/4844241/Realism My Music: https://soundcloud.com/l-spiro
L. Spiro Engine: http://lspiroengine.com
L. Spiro Engine Forums: http://lspiroengine.com/forums