\r
/* Platform-specific includes */\r
#if TARGET_HOST_POSIX_X11\r
+typedef struct tagSFG_PlatformDisplay SFG_PlatformDisplay;\r
+struct tagSFG_PlatformDisplay\r
+{\r
+ Display* Display; /* The display we are being run in. */\r
+ int Screen; /* The screen we are about to use. */\r
+ Window RootWindow; /* The screen's root window. */\r
+ int Connection; /* The display's connection number */\r
+ Atom DeleteWindow; /* The window deletion atom */\r
+ Atom State; /* The state atom */\r
+ Atom StateFullScreen; /* The full screen atom */\r
+\r
+#ifdef HAVE_X11_EXTENSIONS_XRANDR_H\r
+ int prev_xsz, prev_ysz;\r
+ int prev_refresh;\r
+ int prev_size_valid;\r
+#endif /* HAVE_X11_EXTENSIONS_XRANDR_H */\r
+\r
+#ifdef HAVE_X11_EXTENSIONS_XF86VMODE_H\r
+ /*\r
+ * XF86VidMode may be compilable even if it fails at runtime. Therefore,\r
+ * the validity of the VidMode has to be tracked\r
+ */\r
+ int DisplayModeValid; /* Flag that indicates runtime status*/\r
+ XF86VidModeModeLine DisplayMode; /* Current screen's display settings */\r
+ int DisplayModeClock; /* The display mode's refresh rate */\r
+ int DisplayViewPortX; /* saved X location of the viewport */\r
+ int DisplayViewPortY; /* saved Y location of the viewport */\r
+#endif /* HAVE_X11_EXTENSIONS_XF86VMODE_H */\r
+\r
+ int DisplayPointerX; /* saved X location of the pointer */\r
+ int DisplayPointerY; /* saved Y location of the pointer */\r
+};\r
+\r
#endif\r
#if TARGET_HOST_MS_WINDOWS\r
#include "../mswin/freeglut_internal_mswin.h"\r
typedef struct tagSFG_Display SFG_Display;\r
struct tagSFG_Display\r
{\r
-#if TARGET_HOST_POSIX_X11\r
- Display* Display; /* The display we are being run in. */\r
- int Screen; /* The screen we are about to use. */\r
- Window RootWindow; /* The screen's root window. */\r
- int Connection; /* The display's connection number */\r
- Atom DeleteWindow; /* The window deletion atom */\r
- Atom State; /* The state atom */\r
- Atom StateFullScreen; /* The full screen atom */\r
-\r
-#ifdef HAVE_X11_EXTENSIONS_XRANDR_H\r
- int prev_xsz, prev_ysz;\r
- int prev_refresh;\r
- int prev_size_valid;\r
-#endif /* HAVE_X11_EXTENSIONS_XRANDR_H */\r
-\r
-#ifdef HAVE_X11_EXTENSIONS_XF86VMODE_H\r
- /*\r
- * XF86VidMode may be compilable even if it fails at runtime. Therefore,\r
- * the validity of the VidMode has to be tracked\r
- */\r
- int DisplayModeValid; /* Flag that indicates runtime status*/\r
- XF86VidModeModeLine DisplayMode; /* Current screen's display settings */\r
- int DisplayModeClock; /* The display mode's refresh rate */\r
- int DisplayViewPortX; /* saved X location of the viewport */\r
- int DisplayViewPortY; /* saved Y location of the viewport */\r
-#endif /* HAVE_X11_EXTENSIONS_XF86VMODE_H */\r
-\r
- int DisplayPointerX; /* saved X location of the pointer */\r
- int DisplayPointerY; /* saved Y location of the pointer */\r
-\r
-#elif TARGET_HOST_MS_WINDOWS\r
- HINSTANCE Instance; /* The application's instance */\r
- DEVMODE DisplayMode; /* Desktop's display settings */\r
- char *DisplayName; /* Display name for multi display support*/ \r
-\r
-#endif\r
+ SFG_PlatformDisplay pDisplay;\r
\r
int ScreenWidth; /* The screen's width in pixels */\r
int ScreenHeight; /* The screen's height in pixels */\r