\r
// Fix issue in TestRenderToMemory when GL_FRONT is the main\r
// buffer being used.\r
- initialDrawBuf = glGetInteger(GL_DRAW_BUFFER);\r
- initialReadBuf = glGetInteger(GL_READ_BUFFER);\r
+// initialDrawBuf = glGetInteger(GL_DRAW_BUFFER);\r
+// initialReadBuf = glGetInteger(GL_READ_BUFFER);\r
+ \r
+ // XXX: This has to be GL_BACK for canvas on Mac\r
+ // Since initialDrawBuf is GL_FRONT for pbuffer, gotta\r
+ // change this value later on ...\r
+ initialDrawBuf = GL_BACK;\r
+ initialReadBuf = GL_BACK;\r
\r
int spaceIdx = versionStr.indexOf(" ");\r
if (spaceIdx >= 1) {\r
if (lastFb == fb) {\r
return;\r
}\r
-\r
+ \r
// generate mipmaps for last FB if needed\r
if (lastFb != null) {\r
for (int i = 0; i < lastFb.getNumColorBuffers(); i++) {\r