]> Chaos Git - corbenik/ctrulib.git/commitdiff
Add gfxGetScreenFormat().
authormtheall <pigman46@gmail.com>
Sat, 20 Dec 2014 05:38:30 +0000 (23:38 -0600)
committermtheall <pigman46@gmail.com>
Sat, 20 Dec 2014 05:38:30 +0000 (23:38 -0600)
libctru/include/3ds/gfx.h
libctru/source/gfx.c

index 7d85eefcc47cb97537e1cf6ff96ba8a04a90141e..9cfcae00d430c4869a090cc7dfc1255a1c880242 100644 (file)
@@ -25,6 +25,7 @@ void gfxExit();
 //control stuff
 void gfxSet3D(bool enable);
 void gfxSetScreenFormat(gfxScreen_t screen, GSP_FramebufferFormats format);
+GSP_FramebufferFormats gfxGetScreenFormat(gfxScreen_t screen);
 void gfxSetDoubleBuffering(gfxScreen_t screen, bool doubleBuffering);
 void gfxFlushBuffers();
 void gfxSwapBuffers();
index 9b499ef0a2ad75b5515e156db1d5282a04feab09..9c9adeda3d4c44a167ca95230f4689d177e8ebd0 100644 (file)
@@ -36,6 +36,13 @@ void gfxSetScreenFormat(gfxScreen_t screen, GSP_FramebufferFormats format) {
         botFormat = format;
 }
 
+GSP_FramebufferFormats gfxGetScreenFormat(gfxScreen_t screen) {
+    if(screen==GFX_TOP)
+        return topFormat;
+    else
+        return botFormat;
+}
+
 void gfxSetDoubleBuffering( gfxScreen_t screen, bool doubleBuffering) {
        doubleBuf[screen] = doubleBuffering ? 1 : 0; // make sure they're the integer values '1' and '0'
 }