Commit be54adcf authored by Zhiyi Zhang's avatar Zhiyi Zhang Committed by Alexandre Julliard

winex11.drv: Support XRandR display device handler.

XRandR supports multiple GPUs and runtime device change compared to Xinerama. Signed-off-by: 's avatarZhiyi Zhang <zzhang@codeweavers.com> Signed-off-by: 's avatarHuw Davies <huw@codeweavers.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent ec09dcf8
...@@ -11976,6 +11976,26 @@ $as_echo "#define HAVE_XRRGETSCREENRESOURCES 1" >>confdefs.h ...@@ -11976,6 +11976,26 @@ $as_echo "#define HAVE_XRRGETSCREENRESOURCES 1" >>confdefs.h
fi fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <X11/Xlib.h>
#include <X11/extensions/Xrandr.h>
int
main ()
{
static typeof(XRRGetProviderResources) *f; if (f) return 0;
;
return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
$as_echo "#define HAVE_XRRGETPROVIDERRESOURCES 1" >>confdefs.h
else
as_fn_append wine_notices "|libxrandr ${notice_platform}development files too old, XRandR display device handler won't be supported."
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi fi
fi fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
......
...@@ -1223,7 +1223,12 @@ then ...@@ -1223,7 +1223,12 @@ then
[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <X11/Xlib.h> [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <X11/Xlib.h>
#include <X11/extensions/Xrandr.h>]], [[static typeof(XRRGetScreenResources) *f; if (f) return 0;]])], #include <X11/extensions/Xrandr.h>]], [[static typeof(XRRGetScreenResources) *f; if (f) return 0;]])],
[AC_DEFINE(HAVE_XRRGETSCREENRESOURCES, 1, [AC_DEFINE(HAVE_XRRGETSCREENRESOURCES, 1,
[Define if Xrandr has the XRRGetScreenResources function])])],,[$X_LIBS $X_EXTRA_LIBS])]) [Define if Xrandr has the XRRGetScreenResources function])])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <X11/Xlib.h>
#include <X11/extensions/Xrandr.h>]], [[static typeof(XRRGetProviderResources) *f; if (f) return 0;]])],
[AC_DEFINE(HAVE_XRRGETPROVIDERRESOURCES, 1,
[Define if Xrandr has the XRRGetProviderResources function])],
[WINE_NOTICE([libxrandr ${notice_platform}development files too old, XRandR display device handler won't be supported.])])],,[$X_LIBS $X_EXTRA_LIBS])])
fi fi
WINE_NOTICE_WITH(xrandr,[test "x$ac_cv_lib_soname_Xrandr" = "x"], WINE_NOTICE_WITH(xrandr,[test "x$ac_cv_lib_soname_Xrandr" = "x"],
[libxrandr ${notice_platform}development files not found, XRandr won't be supported.]) [libxrandr ${notice_platform}development files not found, XRandr won't be supported.])
......
...@@ -641,6 +641,7 @@ extern POINT virtual_screen_to_root( INT x, INT y ) DECLSPEC_HIDDEN; ...@@ -641,6 +641,7 @@ extern POINT virtual_screen_to_root( INT x, INT y ) DECLSPEC_HIDDEN;
extern POINT root_to_virtual_screen( INT x, INT y ) DECLSPEC_HIDDEN; extern POINT root_to_virtual_screen( INT x, INT y ) DECLSPEC_HIDDEN;
extern RECT get_virtual_screen_rect(void) DECLSPEC_HIDDEN; extern RECT get_virtual_screen_rect(void) DECLSPEC_HIDDEN;
extern RECT get_primary_monitor_rect(void) DECLSPEC_HIDDEN; extern RECT get_primary_monitor_rect(void) DECLSPEC_HIDDEN;
extern void query_work_area( RECT *rc_work ) DECLSPEC_HIDDEN;
extern void xinerama_init( unsigned int width, unsigned int height ) DECLSPEC_HIDDEN; extern void xinerama_init( unsigned int width, unsigned int height ) DECLSPEC_HIDDEN;
struct x11drv_mode_info struct x11drv_mode_info
......
...@@ -55,7 +55,7 @@ static inline MONITORINFOEXW *get_primary(void) ...@@ -55,7 +55,7 @@ static inline MONITORINFOEXW *get_primary(void)
return &monitors[idx]; return &monitors[idx];
} }
static void query_work_area( RECT *rc_work ) void query_work_area( RECT *rc_work )
{ {
Atom type; Atom type;
int format; int format;
......
...@@ -1280,6 +1280,9 @@ ...@@ -1280,6 +1280,9 @@
/* Define if Xrender has the XRenderSetPictureTransform function */ /* Define if Xrender has the XRenderSetPictureTransform function */
#undef HAVE_XRENDERSETPICTURETRANSFORM #undef HAVE_XRENDERSETPICTURETRANSFORM
/* Define if Xrandr has the XRRGetProviderResources function */
#undef HAVE_XRRGETPROVIDERRESOURCES
/* Define if Xrandr has the XRRGetScreenResources function */ /* Define if Xrandr has the XRRGetScreenResources function */
#undef HAVE_XRRGETSCREENRESOURCES #undef HAVE_XRRGETSCREENRESOURCES
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment