[mupen64plus-video-arachnoid] 81/147: Imported Upstream version 1.99.4+39+ada2d63714fd

Sven Eckelmann ecsv-guest at moszumanska.debian.org
Thu Nov 26 06:09:51 UTC 2015


This is an automated email from the git hooks/post-receive script.

ecsv-guest pushed a commit to branch master
in repository mupen64plus-video-arachnoid.

commit c841238c1250ddf4b23c47efec9fe6eda985e093
Author: Sven Eckelmann <sven at narfation.org>
Date:   Sun Mar 11 19:53:44 2012 +0100

    Imported Upstream version 1.99.4+39+ada2d63714fd
---
 src/GraphicsPlugin.cpp | 2 +-
 src/OpenGLManager.cpp  | 3 ++-
 src/OpenGLManager.h    | 8 ++++++--
 src/main.cpp           | 6 +++---
 4 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/src/GraphicsPlugin.cpp b/src/GraphicsPlugin.cpp
index 810a1a2..1afc14e 100755
--- a/src/GraphicsPlugin.cpp
+++ b/src/GraphicsPlugin.cpp
@@ -467,7 +467,7 @@ void GraphicsPlugin::processDisplayList()
 
     //glFlush();    
     //OpenGLManager::getSingleton().endRendering();
-
+	OpenGLManager::getSingleton().setDrawFlag();
     //Take screenshot?
 }
 
diff --git a/src/OpenGLManager.cpp b/src/OpenGLManager.cpp
index 8ab8c64..09ef31f 100755
--- a/src/OpenGLManager.cpp
+++ b/src/OpenGLManager.cpp
@@ -138,7 +138,8 @@ void OpenGLManager::endRendering()
 {
     glFinish();
     if (m_renderingCallback)
-        m_renderingCallback();
+        m_renderingCallback(m_drawFlag);
+	m_drawFlag = 0;
     CoreVideo_GL_SwapBuffers();
     //glFlush();
 }
diff --git a/src/OpenGLManager.h b/src/OpenGLManager.h
index ec2c303..380a8c3 100755
--- a/src/OpenGLManager.h
+++ b/src/OpenGLManager.h
@@ -93,7 +93,10 @@ public:
     void setClearColor(float r, float g, float b) { glClearColor(r, g, b, 1.0f); }
 
     //Set callback from the M64P core
-    void setRenderingCallback(void(*callback)()) { m_renderingCallback = callback; }
+    void setRenderingCallback(void(*callback)(int)) { m_renderingCallback = callback; }
+	
+	//Set draw flag for rendering callback
+	void setDrawFlag() { m_drawFlag = 1; }
 
 public:
 
@@ -128,7 +131,8 @@ private:
     bool m_fullscreen;           //!< Fullscreen mode or window mode?
     bool m_forceDisableCulling;  //!< Culling cant be enabled if this is true
     
-    void (*m_renderingCallback)();  //Rendering callback from the core
+    void (*m_renderingCallback)(int);  //Rendering callback from the core
+	int m_drawFlag;
 };
 
 #endif
diff --git a/src/main.cpp b/src/main.cpp
index 515516e..8962663 100755
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -39,7 +39,7 @@
 //Definitions
 #define PLUGIN_NAME "Arachnoid Video Plugin"
 #define PLUGIN_VERSION           0x016304
-#define VIDEO_PLUGIN_API_VERSION 0x020000
+#define VIDEO_PLUGIN_API_VERSION 0x020100
 #define CONFIG_API_VERSION       0x020000
 #define VIDEXT_API_VERSION       0x020000
 
@@ -57,7 +57,7 @@ GFX_INFO          g_graphicsInfo;                                //!< Informatio
 GraphicsPlugin    g_graphicsPlugin;                              //!< Main class for application
 Config            g_config(&g_graphicsPlugin);                   //!< Handles configuration
 
-void (*renderCallback)() = NULL;
+void (*renderCallback)(int) = NULL;
 
 
 /* definitions of pointers to Core config functions */
@@ -404,7 +404,7 @@ EXPORT void CALL ReadScreen2(void *dest, int *width, int *height, int front)
 //! Allows the core to register a callback function that will be called by the 
 //! graphics plugin just before the the frame buffers are swapped.
 //-----------------------------------------------------------------------------
-EXPORT void CALL SetRenderingCallback(void (*callback)())
+EXPORT void CALL SetRenderingCallback(void (*callback)(int))
 {
     OpenGLManager::getSingleton().setRenderingCallback(callback);
 }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/mupen64plus-video-arachnoid.git



More information about the Pkg-games-commits mailing list