[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [54380] trunk/blender/intern/ghost/intern: building ghost-sdl works again.
Campbell Barton
ideasman42 at gmail.com
Fri Feb 8 09:02:06 CET 2013
Revision: 54380
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=54380
Author: campbellbarton
Date: 2013-02-08 08:02:05 +0000 (Fri, 08 Feb 2013)
Log Message:
-----------
building ghost-sdl works again.
Modified Paths:
--------------
trunk/blender/intern/ghost/intern/GHOST_SystemSDL.cpp
trunk/blender/intern/ghost/intern/GHOST_SystemSDL.h
Modified: trunk/blender/intern/ghost/intern/GHOST_SystemSDL.cpp
===================================================================
--- trunk/blender/intern/ghost/intern/GHOST_SystemSDL.cpp 2013-02-08 04:43:36 UTC (rev 54379)
+++ trunk/blender/intern/ghost/intern/GHOST_SystemSDL.cpp 2013-02-08 08:02:05 UTC (rev 54380)
@@ -114,7 +114,21 @@
return GHOST_kFailure;
}
+/**
+ * Returns the dimensions of the main display on this system.
+ * \return The dimension of the main display.
+ */
void
+GHOST_SystemSDL::getAllDisplayDimensions(GHOST_TUns32& width,
+ GHOST_TUns32& height) const
+{
+ SDL_DisplayMode mode;
+ SDL_GetDesktopDisplayMode(0, &mode); /* note, always 0 display */
+ width = mode.w;
+ height = mode.h;
+}
+
+void
GHOST_SystemSDL::getMainDisplayDimensions(GHOST_TUns32& width,
GHOST_TUns32& height) const
{
Modified: trunk/blender/intern/ghost/intern/GHOST_SystemSDL.h
===================================================================
--- trunk/blender/intern/ghost/intern/GHOST_SystemSDL.h 2013-02-08 04:43:36 UTC (rev 54379)
+++ trunk/blender/intern/ghost/intern/GHOST_SystemSDL.h 2013-02-08 08:02:05 UTC (rev 54380)
@@ -88,6 +88,10 @@
GHOST_TInt32 y);
void
+ getAllDisplayDimensions(GHOST_TUns32& width,
+ GHOST_TUns32& height) const;
+
+ void
getMainDisplayDimensions(GHOST_TUns32& width,
GHOST_TUns32& height) const;
More information about the Bf-blender-cvs
mailing list