Nux

Merge lp:~hikiko/nux/nux.removed-projections-from-modelview into lp:nux

Proposed by Eleni Maria Stea
Status: Merged
Approved by: Stephen M. Webb
Approved revision: 858
Merged at revision: 857
Proposed branch: lp:~hikiko/nux/nux.removed-projections-from-modelview
Merge into: lp:nux
Diff against target: 20 lines (+2/-2)
1 file modified
NuxGraphics/GraphicsEngine.cpp (+2/-2)
To merge this branch: bzr merge lp:~hikiko/nux/nux.removed-projections-from-modelview
Reviewer Review Type Date Requested Status
Stephen M. Webb (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Review via email: mp+254593@code.launchpad.net

Commit message

glFrustrum should be performed in projection mode, otherwise the modelview matrix has projection elements and the lighting and 3d clipping planes of unity and other compiz plugins that load this modelview matrix are buggy.

Description of the change

glFrustrum should be performed in projection mode, otherwise the modelview matrix has projection elements and the lighting and 3d clipping planes of unity and other compiz plugins that load this modelview matrix are buggy.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Stephen M. Webb (bregma) wrote :

Setting the frustum on the modelview matrix is just crazy, It's surprising this bug made it this far.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'NuxGraphics/GraphicsEngine.cpp'
2--- NuxGraphics/GraphicsEngine.cpp 2013-10-30 23:22:52 +0000
3+++ NuxGraphics/GraphicsEngine.cpp 2015-03-30 15:23:28 +0000
4@@ -830,8 +830,6 @@
5 #ifndef NUX_OPENGLES_20
6 CHECKGL(glMatrixMode(GL_PROJECTION));
7 CHECKGL(glLoadIdentity());
8- CHECKGL(glMatrixMode(GL_MODELVIEW));
9- CHECKGL(glLoadIdentity());
10 CHECKGL(glFrustum(
11 -1.0, // left
12 1.0, // right
13@@ -840,6 +838,8 @@
14 0.1, // near,
15 2000.0 // far
16 ));
17+ CHECKGL(glMatrixMode(GL_MODELVIEW));
18+ CHECKGL(glLoadIdentity());
19 #endif
20 }
21

Subscribers

People subscribed via source and target branches