mGBA Forums
void* outputFramebuffer for both GFX_LEFT and GFX_RIGHT - Printable Version

+- mGBA Forums (https://forums.mgba.io)
+-- Forum: mGBA (https://forums.mgba.io/forumdisplay.php?fid=1)
+--- Forum: General (https://forums.mgba.io/forumdisplay.php?fid=3)
+--- Thread: void* outputFramebuffer for both GFX_LEFT and GFX_RIGHT (/showthread.php?tid=385)



void* outputFramebuffer for both GFX_LEFT and GFX_RIGHT - Robin - 02-16-2016

I'm trying to enable 3D mode in mgba. This line here

Code:
void* outputFramebuffer = gfxGetFramebuffer(GFX_TOP, GFX_LEFT, &height, &width);

draws the left screen of the top screen. I want to simultaniously draw the right screen to enable 3D (like when you slide the 3D slider to the top). I have tried numerous approaches but nothing worked.

Code:
void* outputFramebuffer = gfxGetFramebuffer(GFX_TOP, GFX_LEFT, &height, &width);
void* outputFramebuffer = gfxGetFramebuffer(GFX_TOP, GFX_RIGHT, &height, &width);
Code:
void* outputFramebuffer = gfxGetFramebuffer(GFX_TOP, GFX_LEFT, &height, &width), outputFramebuffer = gfxGetFramebuffer(GFX_TOP, GFX_RIGHT, &height, &width);

and so on. Every time I got a compile error. What am I doing wrong? How is it supposed to work? Pleas help me.


RE: void* outputFramebuffer for both GFX_LEFT and GFX_RIGHT - Robin - 02-22-2016

Please, anybody. I still haven't figured it out. I just want to see how good it looks and whether or not it impacts performance.