Kirill: Fixed Mac issue where canvas wouldn't render anything when framebuffers were used
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7447 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
parent
d7995b4a6a
commit
8ace54916f
@ -202,8 +202,14 @@ public class LwjglRenderer implements Renderer {
|
|||||||
|
|
||||||
// Fix issue in TestRenderToMemory when GL_FRONT is the main
|
// Fix issue in TestRenderToMemory when GL_FRONT is the main
|
||||||
// buffer being used.
|
// buffer being used.
|
||||||
initialDrawBuf = glGetInteger(GL_DRAW_BUFFER);
|
// initialDrawBuf = glGetInteger(GL_DRAW_BUFFER);
|
||||||
initialReadBuf = glGetInteger(GL_READ_BUFFER);
|
// initialReadBuf = glGetInteger(GL_READ_BUFFER);
|
||||||
|
|
||||||
|
// XXX: This has to be GL_BACK for canvas on Mac
|
||||||
|
// Since initialDrawBuf is GL_FRONT for pbuffer, gotta
|
||||||
|
// change this value later on ...
|
||||||
|
initialDrawBuf = GL_BACK;
|
||||||
|
initialReadBuf = GL_BACK;
|
||||||
|
|
||||||
int spaceIdx = versionStr.indexOf(" ");
|
int spaceIdx = versionStr.indexOf(" ");
|
||||||
if (spaceIdx >= 1) {
|
if (spaceIdx >= 1) {
|
||||||
@ -1395,7 +1401,7 @@ public class LwjglRenderer implements Renderer {
|
|||||||
if (lastFb == fb) {
|
if (lastFb == fb) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// generate mipmaps for last FB if needed
|
// generate mipmaps for last FB if needed
|
||||||
if (lastFb != null) {
|
if (lastFb != null) {
|
||||||
for (int i = 0; i < lastFb.getNumColorBuffers(); i++) {
|
for (int i = 0; i < lastFb.getNumColorBuffers(); i++) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user