Compare commits
1 Commits
master
...
rfc/drop-x
Author | SHA1 | Date | |
---|---|---|---|
|
685b4e8f2b |
|
@ -65,12 +65,6 @@ libxserver_xext = static_library('libxserver_xext',
|
||||||
dependencies: common_dep,
|
dependencies: common_dep,
|
||||||
)
|
)
|
||||||
|
|
||||||
libxserver_xext_vidmode = static_library('libxserver_xext_vidmode',
|
|
||||||
'vidmode.c',
|
|
||||||
include_directories: inc,
|
|
||||||
dependencies: common_dep,
|
|
||||||
)
|
|
||||||
|
|
||||||
if build_xorg
|
if build_xorg
|
||||||
install_data(hdrs_xext, install_dir: xorgsdkdir)
|
install_data(hdrs_xext, install_dir: xorgsdkdir)
|
||||||
endif
|
endif
|
||||||
|
|
2128
Xext/vidmode.c
2128
Xext/vidmode.c
File diff suppressed because it is too large
Load Diff
|
@ -697,35 +697,6 @@ E004 XFree86-Misc:BadKbdType
|
||||||
E005 XFree86-Misc:ModInDevDisabled
|
E005 XFree86-Misc:ModInDevDisabled
|
||||||
E006 XFree86-Misc:ModInDevClientNotLocal
|
E006 XFree86-Misc:ModInDevClientNotLocal
|
||||||
E007 XFree86-Misc:NoModule
|
E007 XFree86-Misc:NoModule
|
||||||
R000 XFree86-VidModeExtension:QueryVersion
|
|
||||||
R001 XFree86-VidModeExtension:GetModeLine
|
|
||||||
R002 XFree86-VidModeExtension:ModModeLine
|
|
||||||
R003 XFree86-VidModeExtension:SwitchMode
|
|
||||||
R004 XFree86-VidModeExtension:GetMonitor
|
|
||||||
R005 XFree86-VidModeExtension:LockModeSwitch
|
|
||||||
R006 XFree86-VidModeExtension:GetAllModeLines
|
|
||||||
R007 XFree86-VidModeExtension:AddModeLine
|
|
||||||
R008 XFree86-VidModeExtension:DeleteModeLine
|
|
||||||
R009 XFree86-VidModeExtension:ValidateModeLine
|
|
||||||
R010 XFree86-VidModeExtension:SwitchToMode
|
|
||||||
R011 XFree86-VidModeExtension:GetViewPort
|
|
||||||
R012 XFree86-VidModeExtension:SetViewPort
|
|
||||||
R013 XFree86-VidModeExtension:GetDotClocks
|
|
||||||
R014 XFree86-VidModeExtension:SetClientVersion
|
|
||||||
R015 XFree86-VidModeExtension:SetGamma
|
|
||||||
R016 XFree86-VidModeExtension:GetGamma
|
|
||||||
R017 XFree86-VidModeExtension:GetGammaRamp
|
|
||||||
R018 XFree86-VidModeExtension:SetGammaRamp
|
|
||||||
R019 XFree86-VidModeExtension:GetGammaRampSize
|
|
||||||
R020 XFree86-VidModeExtension:GetPermissions
|
|
||||||
V000 XFree86-VidModeExtension:Notify
|
|
||||||
E000 XFree86-VidModeExtension:BadClock
|
|
||||||
E001 XFree86-VidModeExtension:BadHTimings
|
|
||||||
E002 XFree86-VidModeExtension:BadVTimings
|
|
||||||
E003 XFree86-VidModeExtension:ModeUnsuitable
|
|
||||||
E004 XFree86-VidModeExtension:ExtensionDisabled
|
|
||||||
E005 XFree86-VidModeExtension:ClientNotLocal
|
|
||||||
E006 XFree86-VidModeExtension:ZoomLocked
|
|
||||||
R000 XINERAMA:QueryVersion
|
R000 XINERAMA:QueryVersion
|
||||||
R001 XINERAMA:GetState
|
R001 XINERAMA:GetState
|
||||||
R002 XINERAMA:GetScreenCount
|
R002 XINERAMA:GetScreenCount
|
||||||
|
|
|
@ -11,7 +11,6 @@ srcs_xorg_common = [
|
||||||
'xf86AutoConfig.c',
|
'xf86AutoConfig.c',
|
||||||
'xf86Option.c',
|
'xf86Option.c',
|
||||||
'xf86Init.c',
|
'xf86Init.c',
|
||||||
'xf86VidMode.c',
|
|
||||||
'xf86fbman.c',
|
'xf86fbman.c',
|
||||||
'xf86cmap.c',
|
'xf86cmap.c',
|
||||||
'xf86Helper.c',
|
'xf86Helper.c',
|
||||||
|
|
|
@ -282,10 +282,6 @@ xf86ServerIsResetting(void);
|
||||||
extern _X_EXPORT Bool
|
extern _X_EXPORT Bool
|
||||||
xf86ServerIsOnlyDetecting(void);
|
xf86ServerIsOnlyDetecting(void);
|
||||||
extern _X_EXPORT Bool
|
extern _X_EXPORT Bool
|
||||||
xf86GetVidModeAllowNonLocal(void);
|
|
||||||
extern _X_EXPORT Bool
|
|
||||||
xf86GetVidModeEnabled(void);
|
|
||||||
extern _X_EXPORT Bool
|
|
||||||
xf86GetModInDevAllowNonLocal(void);
|
xf86GetModInDevAllowNonLocal(void);
|
||||||
extern _X_EXPORT Bool
|
extern _X_EXPORT Bool
|
||||||
xf86GetModInDevEnabled(void);
|
xf86GetModInDevEnabled(void);
|
||||||
|
|
|
@ -811,13 +811,6 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
|
||||||
* settings may be overridden later when the command line options are
|
* settings may be overridden later when the command line options are
|
||||||
* checked.
|
* checked.
|
||||||
*/
|
*/
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
if (xf86GetOptValBool(FlagOptions, FLAG_DISABLEVIDMODE, &value))
|
|
||||||
xf86Info.vidModeEnabled = !value;
|
|
||||||
if (xf86GetOptValBool(FlagOptions, FLAG_ALLOWNONLOCAL, &value))
|
|
||||||
xf86Info.vidModeAllowNonLocal = value;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (xf86GetOptValBool(FlagOptions, FLAG_ALLOWMOUSEOPENFAIL, &value))
|
if (xf86GetOptValBool(FlagOptions, FLAG_ALLOWMOUSEOPENFAIL, &value))
|
||||||
xf86Info.allowMouseOpenFail = value;
|
xf86Info.allowMouseOpenFail = value;
|
||||||
|
|
||||||
|
@ -2464,13 +2457,6 @@ xf86HandleConfigFile(Bool autoconfig)
|
||||||
* Handle some command line options that can override some of the
|
* Handle some command line options that can override some of the
|
||||||
* ServerFlags settings.
|
* ServerFlags settings.
|
||||||
*/
|
*/
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
if (xf86VidModeDisabled)
|
|
||||||
xf86Info.vidModeEnabled = FALSE;
|
|
||||||
if (xf86VidModeAllowNonLocal)
|
|
||||||
xf86Info.vidModeAllowNonLocal = TRUE;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (xf86AllowMouseOpenFail)
|
if (xf86AllowMouseOpenFail)
|
||||||
xf86Info.allowMouseOpenFail = TRUE;
|
xf86Info.allowMouseOpenFail = TRUE;
|
||||||
|
|
||||||
|
|
|
@ -46,11 +46,6 @@
|
||||||
#include <X11/extensions/xf86dgaproto.h>
|
#include <X11/extensions/xf86dgaproto.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
#include <X11/extensions/xf86vmproto.h>
|
|
||||||
#include "vidmodestr.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
Bool noXFree86VidModeExtension = FALSE;
|
Bool noXFree86VidModeExtension = FALSE;
|
||||||
Bool noXFree86DGAExtension = FALSE;
|
Bool noXFree86DGAExtension = FALSE;
|
||||||
Bool noXFree86DRIExtension = FALSE;
|
Bool noXFree86DRIExtension = FALSE;
|
||||||
|
@ -60,13 +55,6 @@ Bool noDRI2Extension = FALSE;
|
||||||
* DDX-specific extensions.
|
* DDX-specific extensions.
|
||||||
*/
|
*/
|
||||||
static const ExtensionModule extensionModules[] = {
|
static const ExtensionModule extensionModules[] = {
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
{
|
|
||||||
XFree86VidModeExtensionInit,
|
|
||||||
XF86VIDMODENAME,
|
|
||||||
&noXFree86VidModeExtension
|
|
||||||
},
|
|
||||||
#endif
|
|
||||||
#ifdef XFreeXDGA
|
#ifdef XFreeXDGA
|
||||||
{
|
{
|
||||||
XFree86DGAExtensionInit,
|
XFree86DGAExtensionInit,
|
||||||
|
|
|
@ -39,12 +39,6 @@ extern _X_EXPORT Bool noDRI2Extension;
|
||||||
extern void DRI2ExtensionInit(void);
|
extern void DRI2ExtensionInit(void);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
#include <X11/extensions/xf86vmproto.h>
|
|
||||||
extern _X_EXPORT Bool noXFree86VidModeExtension;
|
|
||||||
extern void XFree86VidModeExtensionInit(void);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef XFreeXDGA
|
#ifdef XFreeXDGA
|
||||||
#include <X11/extensions/xf86dgaproto.h>
|
#include <X11/extensions/xf86dgaproto.h>
|
||||||
extern _X_EXPORT Bool noXFree86DGAExtension;
|
extern _X_EXPORT Bool noXFree86DGAExtension;
|
||||||
|
|
|
@ -193,9 +193,4 @@ Gamma xf86Gamma = { 0.0, 0.0, 0.0 };
|
||||||
|
|
||||||
Bool xf86AllowMouseOpenFail = FALSE;
|
Bool xf86AllowMouseOpenFail = FALSE;
|
||||||
Bool xf86AutoBindGPUDisabled = FALSE;
|
Bool xf86AutoBindGPUDisabled = FALSE;
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
Bool xf86VidModeDisabled = FALSE;
|
|
||||||
Bool xf86VidModeAllowNonLocal = FALSE;
|
|
||||||
#endif
|
|
||||||
Bool xorgHWAccess = FALSE;
|
Bool xorgHWAccess = FALSE;
|
||||||
|
|
|
@ -1409,18 +1409,6 @@ xf86ServerIsOnlyDetecting(void)
|
||||||
return xf86DoConfigure;
|
return xf86DoConfigure;
|
||||||
}
|
}
|
||||||
|
|
||||||
Bool
|
|
||||||
xf86GetVidModeAllowNonLocal(void)
|
|
||||||
{
|
|
||||||
return xf86Info.vidModeAllowNonLocal;
|
|
||||||
}
|
|
||||||
|
|
||||||
Bool
|
|
||||||
xf86GetVidModeEnabled(void)
|
|
||||||
{
|
|
||||||
return xf86Info.vidModeEnabled;
|
|
||||||
}
|
|
||||||
|
|
||||||
Bool
|
Bool
|
||||||
xf86GetModInDevAllowNonLocal(void)
|
xf86GetModInDevAllowNonLocal(void)
|
||||||
{
|
{
|
||||||
|
|
|
@ -949,16 +949,6 @@ ddxProcessArgument(int argc, char **argv, int i)
|
||||||
xf86FlipPixels = TRUE;
|
xf86FlipPixels = TRUE;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
if (!strcmp(argv[i], "-disableVidMode")) {
|
|
||||||
xf86VidModeDisabled = TRUE;
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
if (!strcmp(argv[i], "-allowNonLocalXvidtune")) {
|
|
||||||
xf86VidModeAllowNonLocal = TRUE;
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
if (!strcmp(argv[i], "-allowMouseOpenFail")) {
|
if (!strcmp(argv[i], "-allowMouseOpenFail")) {
|
||||||
xf86AllowMouseOpenFail = TRUE;
|
xf86AllowMouseOpenFail = TRUE;
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -1229,11 +1219,6 @@ ddxUseMsg(void)
|
||||||
("-pointer name specify the core pointer InputDevice name\n");
|
("-pointer name specify the core pointer InputDevice name\n");
|
||||||
ErrorF("-nosilk disable Silken Mouse\n");
|
ErrorF("-nosilk disable Silken Mouse\n");
|
||||||
ErrorF("-flipPixels swap default black/white Pixel values\n");
|
ErrorF("-flipPixels swap default black/white Pixel values\n");
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
ErrorF("-disableVidMode disable mode adjustments with xvidtune\n");
|
|
||||||
ErrorF
|
|
||||||
("-allowNonLocalXvidtune allow xvidtune to be run as a non-local client\n");
|
|
||||||
#endif
|
|
||||||
ErrorF
|
ErrorF
|
||||||
("-allowMouseOpenFail start server even if the mouse can't be initialized\n");
|
("-allowMouseOpenFail start server even if the mouse can't be initialized\n");
|
||||||
ErrorF("-ignoreABI make module ABI mismatches non-fatal\n");
|
ErrorF("-ignoreABI make module ABI mismatches non-fatal\n");
|
||||||
|
|
|
@ -48,10 +48,6 @@ extern _X_EXPORT const char *xf86ConfigDir;
|
||||||
extern _X_EXPORT Bool xf86AllowMouseOpenFail;
|
extern _X_EXPORT Bool xf86AllowMouseOpenFail;
|
||||||
extern _X_EXPORT Bool xf86AutoBindGPUDisabled;
|
extern _X_EXPORT Bool xf86AutoBindGPUDisabled;
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
extern _X_EXPORT Bool xf86VidModeDisabled;
|
|
||||||
extern _X_EXPORT Bool xf86VidModeAllowNonLocal;
|
|
||||||
#endif
|
|
||||||
extern _X_EXPORT Bool xf86fpFlag;
|
extern _X_EXPORT Bool xf86fpFlag;
|
||||||
extern _X_EXPORT Bool xf86sFlag;
|
extern _X_EXPORT Bool xf86sFlag;
|
||||||
extern _X_EXPORT Bool xf86bsEnableFlag;
|
extern _X_EXPORT Bool xf86bsEnableFlag;
|
||||||
|
|
|
@ -1,463 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright (c) 1999-2003 by The XFree86 Project, Inc.
|
|
||||||
*
|
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
|
||||||
* to deal in the Software without restriction, including without limitation
|
|
||||||
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
|
||||||
* and/or sell copies of the Software, and to permit persons to whom the
|
|
||||||
* Software is furnished to do so, subject to the following conditions:
|
|
||||||
*
|
|
||||||
* The above copyright notice and this permission notice shall be included in
|
|
||||||
* all copies or substantial portions of the Software.
|
|
||||||
*
|
|
||||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
||||||
* THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
|
||||||
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
|
||||||
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
||||||
* OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
*
|
|
||||||
* Except as contained in this notice, the name of the copyright holder(s)
|
|
||||||
* and author(s) shall not be used in advertising or otherwise to promote
|
|
||||||
* the sale, use or other dealings in this Software without prior written
|
|
||||||
* authorization from the copyright holder(s) and author(s).
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* This file contains the VidMode functions required by the extension.
|
|
||||||
* These have been added to avoid the need for the higher level extension
|
|
||||||
* code to access the private XFree86 data structures directly. Wherever
|
|
||||||
* possible this code uses the functions in xf86Mode.c to do the work,
|
|
||||||
* so that two version of code that do similar things don't have to be
|
|
||||||
* maintained.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifdef HAVE_XORG_CONFIG_H
|
|
||||||
#include <xorg-config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <X11/X.h>
|
|
||||||
#include "os.h"
|
|
||||||
#include "xf86.h"
|
|
||||||
#include "xf86Priv.h"
|
|
||||||
#include "extinit.h"
|
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
#include "vidmodestr.h"
|
|
||||||
#include "xf86Privstr.h"
|
|
||||||
#include "xf86Extensions.h"
|
|
||||||
#include "xf86cmap.h"
|
|
||||||
|
|
||||||
static vidMonitorValue
|
|
||||||
xf86VidModeGetMonitorValue(ScreenPtr pScreen, int valtyp, int indx)
|
|
||||||
{
|
|
||||||
vidMonitorValue ret = { NULL, };
|
|
||||||
MonPtr monitor;
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
monitor = pScrn->monitor;
|
|
||||||
|
|
||||||
switch (valtyp) {
|
|
||||||
case VIDMODE_MON_VENDOR:
|
|
||||||
ret.ptr = monitor->vendor;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_MODEL:
|
|
||||||
ret.ptr = monitor->model;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_NHSYNC:
|
|
||||||
ret.i = monitor->nHsync;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_NVREFRESH:
|
|
||||||
ret.i = monitor->nVrefresh;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_HSYNC_LO:
|
|
||||||
ret.f = (100.0 * monitor->hsync[indx].lo);
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_HSYNC_HI:
|
|
||||||
ret.f = (100.0 * monitor->hsync[indx].hi);
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_VREFRESH_LO:
|
|
||||||
ret.f = (100.0 * monitor->vrefresh[indx].lo);
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_VREFRESH_HI:
|
|
||||||
ret.f = (100.0 * monitor->vrefresh[indx].hi);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeGetCurrentModeline(ScreenPtr pScreen, DisplayModePtr *mode, int *dotClock)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
|
|
||||||
if (pScrn->currentMode) {
|
|
||||||
*mode = pScrn->currentMode;
|
|
||||||
*dotClock = pScrn->currentMode->Clock;
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
xf86VidModeGetDotClock(ScreenPtr pScreen, int Clock)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
if ((pScrn->progClock) || (Clock >= MAXCLOCKS))
|
|
||||||
return Clock;
|
|
||||||
else
|
|
||||||
return pScrn->clock[Clock];
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
xf86VidModeGetNumOfClocks(ScreenPtr pScreen, Bool *progClock)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
if (pScrn->progClock) {
|
|
||||||
*progClock = TRUE;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
*progClock = FALSE;
|
|
||||||
return pScrn->numClocks;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeGetClocks(ScreenPtr pScreen, int *Clocks)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
int i;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
|
|
||||||
if (pScrn->progClock)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
for (i = 0; i < pScrn->numClocks; i++)
|
|
||||||
*Clocks++ = pScrn->clock[i];
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeGetNextModeline(ScreenPtr pScreen, DisplayModePtr *mode, int *dotClock)
|
|
||||||
{
|
|
||||||
VidModePtr pVidMode;
|
|
||||||
DisplayModePtr p;
|
|
||||||
|
|
||||||
pVidMode = VidModeGetPtr(pScreen);
|
|
||||||
|
|
||||||
for (p = pVidMode->Next; p != NULL && p != pVidMode->First; p = p->next) {
|
|
||||||
if (p->status == MODE_OK) {
|
|
||||||
pVidMode->Next = p->next;
|
|
||||||
*mode = p;
|
|
||||||
*dotClock = xf86VidModeGetDotClock(pScreen, p->Clock);
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeGetFirstModeline(ScreenPtr pScreen, DisplayModePtr *mode, int *dotClock)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
VidModePtr pVidMode;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
if (pScrn->modes == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
pVidMode = VidModeGetPtr(pScreen);
|
|
||||||
pVidMode->First = pScrn->modes;
|
|
||||||
pVidMode->Next = pVidMode->First->next;
|
|
||||||
|
|
||||||
if (pVidMode->First->status == MODE_OK) {
|
|
||||||
*mode = pVidMode->First;
|
|
||||||
*dotClock = xf86VidModeGetDotClock(pScreen, pVidMode->First->Clock);
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return xf86VidModeGetNextModeline(pScreen, mode, dotClock);
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeDeleteModeline(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
if (mode == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
xf86DeleteMode(&(pScrn->modes), mode);
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeZoomViewport(ScreenPtr pScreen, int zoom)
|
|
||||||
{
|
|
||||||
xf86ZoomViewport(pScreen, zoom);
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeSetViewPort(ScreenPtr pScreen, int x, int y)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
pScrn->frameX0 = min(max(x, 0),
|
|
||||||
pScrn->virtualX - pScrn->currentMode->HDisplay);
|
|
||||||
pScrn->frameX1 = pScrn->frameX0 + pScrn->currentMode->HDisplay - 1;
|
|
||||||
pScrn->frameY0 = min(max(y, 0),
|
|
||||||
pScrn->virtualY - pScrn->currentMode->VDisplay);
|
|
||||||
pScrn->frameY1 = pScrn->frameY0 + pScrn->currentMode->VDisplay - 1;
|
|
||||||
if (pScrn->AdjustFrame != NULL)
|
|
||||||
(pScrn->AdjustFrame) (pScrn, pScrn->frameX0, pScrn->frameY0);
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeGetViewPort(ScreenPtr pScreen, int *x, int *y)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
*x = pScrn->frameX0;
|
|
||||||
*y = pScrn->frameY0;
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeSwitchMode(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
DisplayModePtr pTmpMode;
|
|
||||||
Bool retval;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
/* save in case we fail */
|
|
||||||
pTmpMode = pScrn->currentMode;
|
|
||||||
/* Force a mode switch */
|
|
||||||
pScrn->currentMode = NULL;
|
|
||||||
retval = xf86SwitchMode(pScrn->pScreen, mode);
|
|
||||||
/* we failed: restore it */
|
|
||||||
if (retval == FALSE)
|
|
||||||
pScrn->currentMode = pTmpMode;
|
|
||||||
return retval;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeLockZoom(ScreenPtr pScreen, Bool lock)
|
|
||||||
{
|
|
||||||
if (xf86Info.dontZoom)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
xf86LockZoom(pScreen, lock);
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static ModeStatus
|
|
||||||
xf86VidModeCheckModeForMonitor(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
if (mode == NULL)
|
|
||||||
return MODE_ERROR;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
|
|
||||||
return xf86CheckModeForMonitor(mode, pScrn->monitor);
|
|
||||||
}
|
|
||||||
|
|
||||||
static ModeStatus
|
|
||||||
xf86VidModeCheckModeForDriver(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
if (mode == NULL)
|
|
||||||
return MODE_ERROR;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
|
|
||||||
return xf86CheckModeForDriver(pScrn, mode, 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
xf86VidModeSetCrtcForMode(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
DisplayModePtr ScreenModes;
|
|
||||||
|
|
||||||
if (mode == NULL)
|
|
||||||
return;
|
|
||||||
|
|
||||||
/* Ugly hack so that the xf86Mode.c function can be used without change */
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
ScreenModes = pScrn->modes;
|
|
||||||
pScrn->modes = mode;
|
|
||||||
|
|
||||||
xf86SetCrtcForModes(pScrn, pScrn->adjustFlags);
|
|
||||||
pScrn->modes = ScreenModes;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeAddModeline(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
if (mode == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
|
|
||||||
mode->name = strdup(""); /* freed by deletemode */
|
|
||||||
mode->status = MODE_OK;
|
|
||||||
mode->next = pScrn->modes->next;
|
|
||||||
mode->prev = pScrn->modes;
|
|
||||||
pScrn->modes->next = mode;
|
|
||||||
if (mode->next != NULL)
|
|
||||||
mode->next->prev = mode;
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
xf86VidModeGetNumOfModes(ScreenPtr pScreen)
|
|
||||||
{
|
|
||||||
DisplayModePtr mode = NULL;
|
|
||||||
int dotClock = 0, nummodes = 0;
|
|
||||||
|
|
||||||
if (!xf86VidModeGetFirstModeline(pScreen, &mode, &dotClock))
|
|
||||||
return nummodes;
|
|
||||||
|
|
||||||
do {
|
|
||||||
nummodes++;
|
|
||||||
if (!xf86VidModeGetNextModeline(pScreen, &mode, &dotClock))
|
|
||||||
return nummodes;
|
|
||||||
} while (TRUE);
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeSetGamma(ScreenPtr pScreen, float red, float green, float blue)
|
|
||||||
{
|
|
||||||
Gamma gamma;
|
|
||||||
|
|
||||||
gamma.red = red;
|
|
||||||
gamma.green = green;
|
|
||||||
gamma.blue = blue;
|
|
||||||
if (xf86ChangeGamma(pScreen, gamma) != Success)
|
|
||||||
return FALSE;
|
|
||||||
else
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeGetGamma(ScreenPtr pScreen, float *red, float *green, float *blue)
|
|
||||||
{
|
|
||||||
ScrnInfoPtr pScrn;
|
|
||||||
|
|
||||||
pScrn = xf86ScreenToScrn(pScreen);
|
|
||||||
*red = pScrn->gamma.red;
|
|
||||||
*green = pScrn->gamma.green;
|
|
||||||
*blue = pScrn->gamma.blue;
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeSetGammaRamp(ScreenPtr pScreen, int size, CARD16 *r, CARD16 *g, CARD16 *b)
|
|
||||||
{
|
|
||||||
xf86ChangeGammaRamp(pScreen, size, r, g, b);
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeGetGammaRamp(ScreenPtr pScreen, int size, CARD16 *r, CARD16 *g, CARD16 *b)
|
|
||||||
{
|
|
||||||
xf86GetGammaRamp(pScreen, size, r, g, b);
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xf86VidModeInit(ScreenPtr pScreen)
|
|
||||||
{
|
|
||||||
VidModePtr pVidMode;
|
|
||||||
|
|
||||||
if (!xf86GetVidModeEnabled()) {
|
|
||||||
DebugF("!xf86GetVidModeEnabled()\n");
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
pVidMode = VidModeInit(pScreen);
|
|
||||||
if (!pVidMode)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
pVidMode->Flags = 0;
|
|
||||||
pVidMode->Next = NULL;
|
|
||||||
|
|
||||||
pVidMode->GetMonitorValue = xf86VidModeGetMonitorValue;
|
|
||||||
pVidMode->GetCurrentModeline = xf86VidModeGetCurrentModeline;
|
|
||||||
pVidMode->GetFirstModeline = xf86VidModeGetFirstModeline;
|
|
||||||
pVidMode->GetNextModeline = xf86VidModeGetNextModeline;
|
|
||||||
pVidMode->DeleteModeline = xf86VidModeDeleteModeline;
|
|
||||||
pVidMode->ZoomViewport = xf86VidModeZoomViewport;
|
|
||||||
pVidMode->GetViewPort = xf86VidModeGetViewPort;
|
|
||||||
pVidMode->SetViewPort = xf86VidModeSetViewPort;
|
|
||||||
pVidMode->SwitchMode = xf86VidModeSwitchMode;
|
|
||||||
pVidMode->LockZoom = xf86VidModeLockZoom;
|
|
||||||
pVidMode->GetNumOfClocks = xf86VidModeGetNumOfClocks;
|
|
||||||
pVidMode->GetClocks = xf86VidModeGetClocks;
|
|
||||||
pVidMode->CheckModeForMonitor = xf86VidModeCheckModeForMonitor;
|
|
||||||
pVidMode->CheckModeForDriver = xf86VidModeCheckModeForDriver;
|
|
||||||
pVidMode->SetCrtcForMode = xf86VidModeSetCrtcForMode;
|
|
||||||
pVidMode->AddModeline = xf86VidModeAddModeline;
|
|
||||||
pVidMode->GetDotClock = xf86VidModeGetDotClock;
|
|
||||||
pVidMode->GetNumOfModes = xf86VidModeGetNumOfModes;
|
|
||||||
pVidMode->SetGamma = xf86VidModeSetGamma;
|
|
||||||
pVidMode->GetGamma = xf86VidModeGetGamma;
|
|
||||||
pVidMode->SetGammaRamp = xf86VidModeSetGammaRamp;
|
|
||||||
pVidMode->GetGammaRamp = xf86VidModeGetGammaRamp;
|
|
||||||
pVidMode->GetGammaRampSize = xf86GetGammaRampSize; /* use xf86cmap API directly */
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
|
||||||
XFree86VidModeExtensionInit(void)
|
|
||||||
{
|
|
||||||
int i;
|
|
||||||
Bool enabled = FALSE;
|
|
||||||
|
|
||||||
DebugF("XFree86VidModeExtensionInit");
|
|
||||||
|
|
||||||
/* This means that the DDX doesn't want the vidmode extension enabled */
|
|
||||||
if (!xf86GetVidModeEnabled())
|
|
||||||
return;
|
|
||||||
|
|
||||||
for (i = 0; i < screenInfo.numScreens; i++) {
|
|
||||||
if (xf86VidModeInit (screenInfo.screens[i]))
|
|
||||||
enabled = TRUE;
|
|
||||||
}
|
|
||||||
/* This means that the DDX doesn't want the vidmode extension enabled */
|
|
||||||
if (!enabled)
|
|
||||||
return;
|
|
||||||
|
|
||||||
VidModeAddExtension(xf86GetVidModeAllowNonLocal());
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif /* XF86VIDMODE */
|
|
|
@ -94,14 +94,6 @@ or initialised. This is equivalent to the
|
||||||
.B AllowMouseOpenFail
|
.B AllowMouseOpenFail
|
||||||
xorg.conf(@filemansuffix@) file option.
|
xorg.conf(@filemansuffix@) file option.
|
||||||
.TP 8
|
.TP 8
|
||||||
.B \-allowNonLocalXvidtune
|
|
||||||
Make the VidMode extension available to remote clients. This allows
|
|
||||||
the xvidtune client to connect from another host. This is equivalent
|
|
||||||
to the
|
|
||||||
.B AllowNonLocalXvidtune
|
|
||||||
xorg.conf(@filemansuffix@) file option. By default non-local
|
|
||||||
connections are not allowed.
|
|
||||||
.TP 8
|
|
||||||
.BI \-bgamma " value"
|
.BI \-bgamma " value"
|
||||||
Set the blue gamma correction.
|
Set the blue gamma correction.
|
||||||
.I value
|
.I value
|
||||||
|
|
|
@ -62,7 +62,6 @@ xorg_link = [
|
||||||
xorg_parser,
|
xorg_parser,
|
||||||
xorg_ramdac,
|
xorg_ramdac,
|
||||||
libxserver_fb,
|
libxserver_fb,
|
||||||
libxserver_xext_vidmode,
|
|
||||||
libxserver_main,
|
libxserver_main,
|
||||||
libxserver_config,
|
libxserver_config,
|
||||||
]
|
]
|
||||||
|
|
|
@ -20,8 +20,6 @@ srcs = [
|
||||||
'xwayland-output.h',
|
'xwayland-output.h',
|
||||||
'xwayland-cvt.c',
|
'xwayland-cvt.c',
|
||||||
'xwayland-cvt.h',
|
'xwayland-cvt.h',
|
||||||
'xwayland-vidmode.c',
|
|
||||||
'xwayland-vidmode.h',
|
|
||||||
'xwayland-window.c',
|
'xwayland-window.c',
|
||||||
'xwayland-window.h',
|
'xwayland-window.h',
|
||||||
'xwayland-window-buffers.c',
|
'xwayland-window-buffers.c',
|
||||||
|
@ -150,7 +148,6 @@ xwayland_server = executable(
|
||||||
xwayland_glamor,
|
xwayland_glamor,
|
||||||
libxserver_fb,
|
libxserver_fb,
|
||||||
libxserver,
|
libxserver,
|
||||||
libxserver_xext_vidmode,
|
|
||||||
libxserver_xkb_stubs,
|
libxserver_xkb_stubs,
|
||||||
libxserver_xi_stubs,
|
libxserver_xi_stubs,
|
||||||
libxserver_glx,
|
libxserver_glx,
|
||||||
|
|
|
@ -1,508 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright (c) 1999-2003 by The XFree86 Project, Inc.
|
|
||||||
*
|
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
|
||||||
* to deal in the Software without restriction, including without limitation
|
|
||||||
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
|
||||||
* and/or sell copies of the Software, and to permit persons to whom the
|
|
||||||
* Software is furnished to do so, subject to the following conditions:
|
|
||||||
*
|
|
||||||
* The above copyright notice and this permission notice shall be included in
|
|
||||||
* all copies or substantial portions of the Software.
|
|
||||||
*
|
|
||||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
||||||
* THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
|
||||||
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
|
||||||
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
||||||
* OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
*
|
|
||||||
* Except as contained in this notice, the name of the copyright holder(s)
|
|
||||||
* and author(s) shall not be used in advertising or otherwise to promote
|
|
||||||
* the sale, use or other dealings in this Software without prior written
|
|
||||||
* authorization from the copyright holder(s) and author(s).
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <dix-config.h>
|
|
||||||
|
|
||||||
#include <X11/X.h>
|
|
||||||
|
|
||||||
#include "dix/dix_priv.h"
|
|
||||||
|
|
||||||
#include "misc.h"
|
|
||||||
#include "os.h"
|
|
||||||
#include "extinit.h"
|
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
|
|
||||||
#include "randrstr.h"
|
|
||||||
#include "vidmodestr.h"
|
|
||||||
|
|
||||||
#include "xwayland-screen.h"
|
|
||||||
#include "xwayland-vidmode.h"
|
|
||||||
|
|
||||||
static DevPrivateKeyRec xwlVidModePrivateKeyRec;
|
|
||||||
#define xwlVidModePrivateKey (&xwlVidModePrivateKeyRec)
|
|
||||||
|
|
||||||
/* Taken from xrandr, h sync frequency in KHz */
|
|
||||||
static double
|
|
||||||
mode_hsync(const xRRModeInfo *mode_info)
|
|
||||||
{
|
|
||||||
double rate;
|
|
||||||
|
|
||||||
if (mode_info->hTotal)
|
|
||||||
rate = (double) mode_info->dotClock / (double) mode_info->hTotal;
|
|
||||||
else
|
|
||||||
rate = 0.0;
|
|
||||||
|
|
||||||
return rate / 1000.0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Taken from xrandr, v refresh frequency in Hz */
|
|
||||||
static double
|
|
||||||
mode_refresh(const xRRModeInfo *mode_info)
|
|
||||||
{
|
|
||||||
double rate;
|
|
||||||
double vTotal = mode_info->vTotal;
|
|
||||||
|
|
||||||
if (mode_info->modeFlags & RR_DoubleScan)
|
|
||||||
vTotal *= 2.0;
|
|
||||||
|
|
||||||
if (mode_info->modeFlags & RR_Interlace)
|
|
||||||
vTotal /= 2.0;
|
|
||||||
|
|
||||||
if (mode_info->hTotal > 0.0 && vTotal > 0.0)
|
|
||||||
rate = ((double) mode_info->dotClock /
|
|
||||||
((double) mode_info->hTotal * (double) vTotal));
|
|
||||||
else
|
|
||||||
rate = 0.0;
|
|
||||||
|
|
||||||
return rate;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
xwlRRModeToDisplayMode(RRModePtr rrmode, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
const xRRModeInfo *mode_info = &rrmode->mode;
|
|
||||||
|
|
||||||
mode->next = mode;
|
|
||||||
mode->prev = mode;
|
|
||||||
mode->name = "";
|
|
||||||
mode->VScan = 1;
|
|
||||||
mode->Private = NULL;
|
|
||||||
mode->HDisplay = mode_info->width;
|
|
||||||
mode->HSyncStart = mode_info->hSyncStart;
|
|
||||||
mode->HSyncEnd = mode_info->hSyncEnd;
|
|
||||||
mode->HTotal = mode_info->hTotal;
|
|
||||||
mode->HSkew = mode_info->hSkew;
|
|
||||||
mode->VDisplay = mode_info->height;
|
|
||||||
mode->VSyncStart = mode_info->vSyncStart;
|
|
||||||
mode->VSyncEnd = mode_info->vSyncEnd;
|
|
||||||
mode->VTotal = mode_info->vTotal;
|
|
||||||
mode->Flags = mode_info->modeFlags;
|
|
||||||
mode->Clock = mode_info->dotClock / 1000.0;
|
|
||||||
mode->VRefresh = mode_refresh(mode_info); /* Or RRVerticalRefresh() */
|
|
||||||
mode->HSync = mode_hsync(mode_info);
|
|
||||||
}
|
|
||||||
|
|
||||||
static RRModePtr
|
|
||||||
xwlVidModeGetRRMode(ScreenPtr pScreen, int32_t width, int32_t height)
|
|
||||||
{
|
|
||||||
struct xwl_screen *xwl_screen = xwl_screen_get(pScreen);
|
|
||||||
struct xwl_output *xwl_output;
|
|
||||||
|
|
||||||
xwl_output = xwl_screen_get_fixed_or_first_output(xwl_screen);
|
|
||||||
if (!xwl_output)
|
|
||||||
return NULL;
|
|
||||||
|
|
||||||
return xwl_output_find_mode(xwl_output, width, height);
|
|
||||||
}
|
|
||||||
|
|
||||||
static RRModePtr
|
|
||||||
xwlVidModeGetCurrentRRMode(ScreenPtr pScreen)
|
|
||||||
{
|
|
||||||
struct xwl_screen *xwl_screen = xwl_screen_get(pScreen);
|
|
||||||
struct xwl_emulated_mode *emulated_mode;
|
|
||||||
struct xwl_output *xwl_output;
|
|
||||||
|
|
||||||
xwl_output = xwl_screen_get_fixed_or_first_output(xwl_screen);
|
|
||||||
if (!xwl_output)
|
|
||||||
return NULL;
|
|
||||||
|
|
||||||
emulated_mode =
|
|
||||||
xwl_output_get_emulated_mode_for_client(xwl_output, GetCurrentClient());
|
|
||||||
|
|
||||||
if (emulated_mode) {
|
|
||||||
return xwl_output_find_mode(xwl_output,
|
|
||||||
emulated_mode->width,
|
|
||||||
emulated_mode->height);
|
|
||||||
} else {
|
|
||||||
return xwl_output_find_mode(xwl_output, -1, -1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeGetCurrentModeline(ScreenPtr pScreen, DisplayModePtr *mode, int *dotClock)
|
|
||||||
{
|
|
||||||
DisplayModePtr pMod;
|
|
||||||
RRModePtr rrmode;
|
|
||||||
|
|
||||||
pMod = dixLookupPrivate(&pScreen->devPrivates, xwlVidModePrivateKey);
|
|
||||||
if (pMod == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
rrmode = xwlVidModeGetCurrentRRMode(pScreen);
|
|
||||||
if (rrmode == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
xwlRRModeToDisplayMode(rrmode, pMod);
|
|
||||||
|
|
||||||
*mode = pMod;
|
|
||||||
if (dotClock != NULL)
|
|
||||||
*dotClock = pMod->Clock;
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static vidMonitorValue
|
|
||||||
xwlVidModeGetMonitorValue(ScreenPtr pScreen, int valtyp, int indx)
|
|
||||||
{
|
|
||||||
vidMonitorValue ret = { NULL, };
|
|
||||||
RRModePtr rrmode;
|
|
||||||
|
|
||||||
rrmode = xwlVidModeGetCurrentRRMode(pScreen);
|
|
||||||
if (rrmode == NULL)
|
|
||||||
return ret;
|
|
||||||
|
|
||||||
switch (valtyp) {
|
|
||||||
case VIDMODE_MON_VENDOR:
|
|
||||||
ret.ptr = XVENDORNAME;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_MODEL:
|
|
||||||
ret.ptr = "XWAYLAND";
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_NHSYNC:
|
|
||||||
ret.i = 1;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_NVREFRESH:
|
|
||||||
ret.i = 1;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_HSYNC_LO:
|
|
||||||
case VIDMODE_MON_HSYNC_HI:
|
|
||||||
ret.f = mode_hsync(&rrmode->mode) * 100.0;
|
|
||||||
break;
|
|
||||||
case VIDMODE_MON_VREFRESH_LO:
|
|
||||||
case VIDMODE_MON_VREFRESH_HI:
|
|
||||||
ret.f = mode_refresh(&rrmode->mode) * 100.0;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
xwlVidModeGetDotClock(ScreenPtr pScreen, int Clock)
|
|
||||||
{
|
|
||||||
return Clock;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
xwlVidModeGetNumOfClocks(ScreenPtr pScreen, Bool *progClock)
|
|
||||||
{
|
|
||||||
/* We emulate a programmable clock, rather then a fixed set of clocks */
|
|
||||||
*progClock = TRUE;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeGetClocks(ScreenPtr pScreen, int *Clocks)
|
|
||||||
{
|
|
||||||
return FALSE; /* Programmable clock, no clock list */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* GetFirstModeline and GetNextModeline are used from Xext/vidmode.c like this:
|
|
||||||
* if (pVidMode->GetFirstModeline(pScreen, &mode, &dotClock)) {
|
|
||||||
* do {
|
|
||||||
* ...
|
|
||||||
* if (...)
|
|
||||||
* break;
|
|
||||||
* } while (pVidMode->GetNextModeline(pScreen, &mode, &dotClock));
|
|
||||||
* }
|
|
||||||
* IOW our caller basically always loops over all the modes. There never is a
|
|
||||||
* return to the mainloop between GetFirstModeline and NextModeline calls where
|
|
||||||
* other parts of the server may change our state so we do not need to worry
|
|
||||||
* about xwl_output->randr_output->modes changing underneath us.
|
|
||||||
* Thus we can simply implement these two callbacks by storing the enumeration
|
|
||||||
* index in pVidMode->Next.
|
|
||||||
*/
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeGetNextModeline(ScreenPtr pScreen, DisplayModePtr *mode, int *dotClock)
|
|
||||||
{
|
|
||||||
struct xwl_screen *xwl_screen = xwl_screen_get(pScreen);
|
|
||||||
struct xwl_output *xwl_output;
|
|
||||||
VidModePtr pVidMode;
|
|
||||||
DisplayModePtr pMod;
|
|
||||||
intptr_t index;
|
|
||||||
|
|
||||||
xwl_output = xwl_screen_get_fixed_or_first_output(xwl_screen);
|
|
||||||
if (xwl_output == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
pMod = dixLookupPrivate(&pScreen->devPrivates, xwlVidModePrivateKey);
|
|
||||||
pVidMode = VidModeGetPtr(pScreen);
|
|
||||||
if (pMod == NULL || pVidMode == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
index = (intptr_t)pVidMode->Next;
|
|
||||||
if (index >= xwl_output->randr_output->numModes)
|
|
||||||
return FALSE;
|
|
||||||
xwlRRModeToDisplayMode(xwl_output->randr_output->modes[index], pMod);
|
|
||||||
index++;
|
|
||||||
pVidMode->Next = (void *)index;
|
|
||||||
|
|
||||||
*mode = pMod;
|
|
||||||
if (dotClock != NULL)
|
|
||||||
*dotClock = pMod->Clock;
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeGetFirstModeline(ScreenPtr pScreen, DisplayModePtr *mode, int *dotClock)
|
|
||||||
{
|
|
||||||
VidModePtr pVidMode;
|
|
||||||
intptr_t index = 0;
|
|
||||||
|
|
||||||
pVidMode = VidModeGetPtr(pScreen);
|
|
||||||
if (pVidMode == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
pVidMode->Next = (void *)index; /* 0 */
|
|
||||||
return xwlVidModeGetNextModeline(pScreen, mode, dotClock);
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeDeleteModeline(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
/* Unsupported */
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeZoomViewport(ScreenPtr pScreen, int zoom)
|
|
||||||
{
|
|
||||||
/* Support only no zoom */
|
|
||||||
return (zoom == 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeSetViewPort(ScreenPtr pScreen, int x, int y)
|
|
||||||
{
|
|
||||||
struct xwl_screen *xwl_screen = xwl_screen_get(pScreen);
|
|
||||||
struct xwl_output *xwl_output;
|
|
||||||
|
|
||||||
xwl_output = xwl_screen_get_fixed_or_first_output(xwl_screen);
|
|
||||||
if (xwl_output == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
/* Support only default viewport */
|
|
||||||
return (x == xwl_output->x && y == xwl_output->y);
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeGetViewPort(ScreenPtr pScreen, int *x, int *y)
|
|
||||||
{
|
|
||||||
struct xwl_screen *xwl_screen = xwl_screen_get(pScreen);
|
|
||||||
struct xwl_output *xwl_output;
|
|
||||||
|
|
||||||
xwl_output = xwl_screen_get_fixed_or_first_output(xwl_screen);
|
|
||||||
if (xwl_output == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
*x = xwl_output->x;
|
|
||||||
*y = xwl_output->y;
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeSwitchMode(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
struct xwl_screen *xwl_screen = xwl_screen_get(pScreen);
|
|
||||||
struct xwl_output *xwl_output;
|
|
||||||
RRModePtr rrmode;
|
|
||||||
|
|
||||||
xwl_output = xwl_screen_get_fixed_or_first_output(xwl_screen);
|
|
||||||
if (xwl_output == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
rrmode = xwl_output_find_mode(xwl_output, mode->HDisplay, mode->VDisplay);
|
|
||||||
if (rrmode == NULL)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
if (xwl_screen->rootless)
|
|
||||||
xwl_output_set_emulated_mode(xwl_output, GetCurrentClient(), rrmode, TRUE);
|
|
||||||
else if (xwl_screen->fixed_output)
|
|
||||||
xwl_output_set_mode_fixed(xwl_screen->fixed_output, rrmode);
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeLockZoom(ScreenPtr pScreen, Bool lock)
|
|
||||||
{
|
|
||||||
/* Unsupported for now, but pretend it works */
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static ModeStatus
|
|
||||||
xwlVidModeCheckModeForMonitor(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
RRModePtr rrmode;
|
|
||||||
|
|
||||||
rrmode = xwlVidModeGetRRMode(pScreen, mode->HDisplay, mode->VDisplay);
|
|
||||||
if (rrmode == NULL)
|
|
||||||
return MODE_ERROR;
|
|
||||||
|
|
||||||
/* Only support mode with the same HSync/VRefresh as we advertise */
|
|
||||||
if (mode->HSync == mode_hsync(&rrmode->mode) &&
|
|
||||||
mode->VRefresh == mode_refresh(&rrmode->mode))
|
|
||||||
return MODE_OK;
|
|
||||||
|
|
||||||
/* All the rest is unsupported - If we want to succeed, return MODE_OK instead */
|
|
||||||
return MODE_ONE_SIZE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static ModeStatus
|
|
||||||
xwlVidModeCheckModeForDriver(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
RRModePtr rrmode;
|
|
||||||
|
|
||||||
rrmode = xwlVidModeGetRRMode(pScreen, mode->HDisplay, mode->VDisplay);
|
|
||||||
return rrmode ? MODE_OK : MODE_ERROR;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
xwlVidModeSetCrtcForMode(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
/* Unsupported */
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeAddModeline(ScreenPtr pScreen, DisplayModePtr mode)
|
|
||||||
{
|
|
||||||
/* Unsupported */
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
xwlVidModeGetNumOfModes(ScreenPtr pScreen)
|
|
||||||
{
|
|
||||||
struct xwl_screen *xwl_screen = xwl_screen_get(pScreen);
|
|
||||||
struct xwl_output *xwl_output;
|
|
||||||
|
|
||||||
xwl_output = xwl_screen_get_fixed_or_first_output(xwl_screen);
|
|
||||||
|
|
||||||
return xwl_output ? xwl_output->randr_output->numModes : 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeSetGamma(ScreenPtr pScreen, float red, float green, float blue)
|
|
||||||
{
|
|
||||||
/* Unsupported for now, but pretend it works */
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeGetGamma(ScreenPtr pScreen, float *red, float *green, float *blue)
|
|
||||||
{
|
|
||||||
/* Unsupported for now, but pretend it works */
|
|
||||||
*red = *green = *blue = 1.0f;
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeSetGammaRamp(ScreenPtr pScreen, int size, CARD16 *r, CARD16 *g, CARD16 *b)
|
|
||||||
{
|
|
||||||
/* Unsupported for now */
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeGetGammaRamp(ScreenPtr pScreen, int size, CARD16 *r, CARD16 *g, CARD16 *b)
|
|
||||||
{
|
|
||||||
/* Unsupported for now */
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
xwlVidModeGetGammaRampSize(ScreenPtr pScreen)
|
|
||||||
{
|
|
||||||
/* Unsupported for now */
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Bool
|
|
||||||
xwlVidModeInit(ScreenPtr pScreen)
|
|
||||||
{
|
|
||||||
VidModePtr pVidMode = NULL;
|
|
||||||
|
|
||||||
pVidMode = VidModeInit(pScreen);
|
|
||||||
if (!pVidMode)
|
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
pVidMode->Flags = 0;
|
|
||||||
pVidMode->Next = NULL;
|
|
||||||
|
|
||||||
pVidMode->GetMonitorValue = xwlVidModeGetMonitorValue;
|
|
||||||
pVidMode->GetCurrentModeline = xwlVidModeGetCurrentModeline;
|
|
||||||
pVidMode->GetFirstModeline = xwlVidModeGetFirstModeline;
|
|
||||||
pVidMode->GetNextModeline = xwlVidModeGetNextModeline;
|
|
||||||
pVidMode->DeleteModeline = xwlVidModeDeleteModeline;
|
|
||||||
pVidMode->ZoomViewport = xwlVidModeZoomViewport;
|
|
||||||
pVidMode->GetViewPort = xwlVidModeGetViewPort;
|
|
||||||
pVidMode->SetViewPort = xwlVidModeSetViewPort;
|
|
||||||
pVidMode->SwitchMode = xwlVidModeSwitchMode;
|
|
||||||
pVidMode->LockZoom = xwlVidModeLockZoom;
|
|
||||||
pVidMode->GetNumOfClocks = xwlVidModeGetNumOfClocks;
|
|
||||||
pVidMode->GetClocks = xwlVidModeGetClocks;
|
|
||||||
pVidMode->CheckModeForMonitor = xwlVidModeCheckModeForMonitor;
|
|
||||||
pVidMode->CheckModeForDriver = xwlVidModeCheckModeForDriver;
|
|
||||||
pVidMode->SetCrtcForMode = xwlVidModeSetCrtcForMode;
|
|
||||||
pVidMode->AddModeline = xwlVidModeAddModeline;
|
|
||||||
pVidMode->GetDotClock = xwlVidModeGetDotClock;
|
|
||||||
pVidMode->GetNumOfModes = xwlVidModeGetNumOfModes;
|
|
||||||
pVidMode->SetGamma = xwlVidModeSetGamma;
|
|
||||||
pVidMode->GetGamma = xwlVidModeGetGamma;
|
|
||||||
pVidMode->SetGammaRamp = xwlVidModeSetGammaRamp;
|
|
||||||
pVidMode->GetGammaRamp = xwlVidModeGetGammaRamp;
|
|
||||||
pVidMode->GetGammaRampSize = xwlVidModeGetGammaRampSize;
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
|
||||||
xwlVidModeExtensionInit(void)
|
|
||||||
{
|
|
||||||
int i;
|
|
||||||
Bool enabled = FALSE;
|
|
||||||
|
|
||||||
for (i = 0; i < screenInfo.numScreens; i++) {
|
|
||||||
if (xwlVidModeInit (screenInfo.screens[i]))
|
|
||||||
enabled = TRUE;
|
|
||||||
}
|
|
||||||
/* This means that the DDX doesn't want the vidmode extension enabled */
|
|
||||||
if (!enabled)
|
|
||||||
return;
|
|
||||||
|
|
||||||
if (!dixRegisterPrivateKey(xwlVidModePrivateKey, PRIVATE_SCREEN,
|
|
||||||
sizeof(DisplayModeRec)))
|
|
||||||
return;
|
|
||||||
|
|
||||||
VidModeAddExtension(FALSE);
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif /* XF86VIDMODE */
|
|
|
@ -1,37 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright (c) 1999-2003 by The XFree86 Project, Inc.
|
|
||||||
*
|
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
|
||||||
* copy of this software and associated documentation files (the "Software"),
|
|
||||||
* to deal in the Software without restriction, including without limitation
|
|
||||||
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
|
||||||
* and/or sell copies of the Software, and to permit persons to whom the
|
|
||||||
* Software is furnished to do so, subject to the following conditions:
|
|
||||||
*
|
|
||||||
* The above copyright notice and this permission notice shall be included in
|
|
||||||
* all copies or substantial portions of the Software.
|
|
||||||
*
|
|
||||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
||||||
* THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
|
||||||
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
|
||||||
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
||||||
* OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
*
|
|
||||||
* Except as contained in this notice, the name of the copyright holder(s)
|
|
||||||
* and author(s) shall not be used in advertising or otherwise to promote
|
|
||||||
* the sale, use or other dealings in this Software without prior written
|
|
||||||
* authorization from the copyright holder(s) and author(s).
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef XWAYLAND_VIDMODE_H
|
|
||||||
#define XWAYLAND_VIDMODE_H
|
|
||||||
|
|
||||||
#include <xwayland-config.h>
|
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
void xwlVidModeExtensionInit(void);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif /* XWAYLAND_VIDMODE_H */
|
|
|
@ -59,12 +59,6 @@
|
||||||
#include "os/auth.h"
|
#include "os/auth.h"
|
||||||
|
|
||||||
#include "xwayland-screen.h"
|
#include "xwayland-screen.h"
|
||||||
#include "xwayland-vidmode.h"
|
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
#include <X11/extensions/xf86vmproto.h>
|
|
||||||
Bool noXFree86VidModeExtension;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
void
|
void
|
||||||
ddxGiveUp(enum ExitCode error)
|
ddxGiveUp(enum ExitCode error)
|
||||||
|
@ -424,9 +418,6 @@ xwlExtensionInit(void)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static const ExtensionModule xwayland_extensions[] = {
|
static const ExtensionModule xwayland_extensions[] = {
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
{ xwlVidModeExtensionInit, XF86VIDMODENAME, &noXFree86VidModeExtension },
|
|
||||||
#endif
|
|
||||||
#ifdef XWL_HAS_XWAYLAND_EXTENSION
|
#ifdef XWL_HAS_XWAYLAND_EXTENSION
|
||||||
{ xwlExtensionInit, XWAYLAND_EXTENSION_NAME, &noXwaylandExtension },
|
{ xwlExtensionInit, XWAYLAND_EXTENSION_NAME, &noXwaylandExtension },
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -232,7 +232,6 @@ conf_data.set('XCSECURITY', build_xsecurity ? '1' : false)
|
||||||
conf_data.set('XDMCP', xdmcp_dep.found() ? '1' : false)
|
conf_data.set('XDMCP', xdmcp_dep.found() ? '1' : false)
|
||||||
conf_data.set('XF86BIGFONT', build_xf86bigfont ? '1' : false)
|
conf_data.set('XF86BIGFONT', build_xf86bigfont ? '1' : false)
|
||||||
conf_data.set('XF86DRI', build_dri1 ? '1' : false)
|
conf_data.set('XF86DRI', build_dri1 ? '1' : false)
|
||||||
conf_data.set('XF86VIDMODE', 1)
|
|
||||||
conf_data.set('XFIXES', '1')
|
conf_data.set('XFIXES', '1')
|
||||||
conf_data.set('XFreeXDGA', build_dga ? '1' : false)
|
conf_data.set('XFreeXDGA', build_dga ? '1' : false)
|
||||||
conf_data.set('XINERAMA', build_xinerama ? '1' : false)
|
conf_data.set('XINERAMA', build_xinerama ? '1' : false)
|
||||||
|
|
|
@ -137,10 +137,6 @@
|
||||||
#define SERVER_XF86DRI_MINOR_VERSION 1
|
#define SERVER_XF86DRI_MINOR_VERSION 1
|
||||||
#define SERVER_XF86DRI_PATCH_VERSION 20040604
|
#define SERVER_XF86DRI_PATCH_VERSION 20040604
|
||||||
|
|
||||||
/* Vidmode */
|
|
||||||
#define SERVER_XF86VIDMODE_MAJOR_VERSION 2
|
|
||||||
#define SERVER_XF86VIDMODE_MINOR_VERSION 2
|
|
||||||
|
|
||||||
/* Fixes */
|
/* Fixes */
|
||||||
#define SERVER_XFIXES_MAJOR_VERSION 6
|
#define SERVER_XFIXES_MAJOR_VERSION 6
|
||||||
#define SERVER_XFIXES_MINOR_VERSION 0
|
#define SERVER_XFIXES_MINOR_VERSION 0
|
||||||
|
|
|
@ -133,10 +133,4 @@ typedef struct {
|
||||||
VidModeGetGammaRampSizeProcPtr GetGammaRampSize;
|
VidModeGetGammaRampSizeProcPtr GetGammaRampSize;
|
||||||
} VidModeRec, *VidModePtr;
|
} VidModeRec, *VidModePtr;
|
||||||
|
|
||||||
#ifdef XF86VIDMODE
|
|
||||||
void VidModeAddExtension(Bool allow_non_local);
|
|
||||||
VidModePtr VidModeGetPtr(ScreenPtr pScreen);
|
|
||||||
VidModePtr VidModeInit(ScreenPtr pScreen);
|
|
||||||
#endif /* XF86VIDMODE */
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -105,9 +105,6 @@
|
||||||
/* Build XFree86 BigFont extension */
|
/* Build XFree86 BigFont extension */
|
||||||
#mesondefine XF86BIGFONT
|
#mesondefine XF86BIGFONT
|
||||||
|
|
||||||
/* Support XFree86 Video Mode extension */
|
|
||||||
#mesondefine XF86VIDMODE
|
|
||||||
|
|
||||||
/* Build XDGA support */
|
/* Build XDGA support */
|
||||||
#mesondefine XFreeXDGA
|
#mesondefine XFreeXDGA
|
||||||
|
|
||||||
|
|
|
@ -97,7 +97,6 @@ dri2proto_dep = dependency('dri2proto', version: '>= 2.8', fallback: ['xorgproto
|
||||||
dri3proto_dep = dependency('dri3proto', version: '>= 1.4', fallback: ['xorgproto', 'ext_xorgproto'], required: get_option('dri3') == 'true')
|
dri3proto_dep = dependency('dri3proto', version: '>= 1.4', fallback: ['xorgproto', 'ext_xorgproto'], required: get_option('dri3') == 'true')
|
||||||
xineramaproto_dep = dependency('xineramaproto', fallback: ['xorgproto', 'ext_xorgproto'])
|
xineramaproto_dep = dependency('xineramaproto', fallback: ['xorgproto', 'ext_xorgproto'])
|
||||||
xf86bigfontproto_dep = dependency('xf86bigfontproto', version: '>= 1.2.0', fallback: ['xorgproto', 'ext_xorgproto'], required: get_option('xf86bigfont'))
|
xf86bigfontproto_dep = dependency('xf86bigfontproto', version: '>= 1.2.0', fallback: ['xorgproto', 'ext_xorgproto'], required: get_option('xf86bigfont'))
|
||||||
xf86vidmodeproto_dep = dependency('xf86vidmodeproto', version: '>= 2.2.99.1', fallback: ['xorgproto', 'ext_xorgproto'])
|
|
||||||
applewmproto_dep = dependency('applewmproto', version: '>= 1.4', fallback: ['xorgproto', 'ext_xorgproto'], required: false)
|
applewmproto_dep = dependency('applewmproto', version: '>= 1.4', fallback: ['xorgproto', 'ext_xorgproto'], required: false)
|
||||||
xshmfence_dep = dependency('xshmfence', version: xshmfence_req, required: false)
|
xshmfence_dep = dependency('xshmfence', version: xshmfence_req, required: false)
|
||||||
xwaylandproto_dep = dependency('xwaylandproto', version: '>= 1.0', fallback: ['xorgproto', 'ext_xorgproto'], required: false)
|
xwaylandproto_dep = dependency('xwaylandproto', version: '>= 1.0', fallback: ['xorgproto', 'ext_xorgproto'], required: false)
|
||||||
|
@ -642,7 +641,6 @@ common_dep = [
|
||||||
xineramaproto_dep,
|
xineramaproto_dep,
|
||||||
xf86bigfontproto_dep,
|
xf86bigfontproto_dep,
|
||||||
xf86dgaproto_dep,
|
xf86dgaproto_dep,
|
||||||
xf86vidmodeproto_dep,
|
|
||||||
applewmproto_dep,
|
applewmproto_dep,
|
||||||
dpmsproto_dep,
|
dpmsproto_dep,
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue