45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Copyright © 2000 Compaq Computer Corporation
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Copyright © 2002 Hewlett-Packard Company
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Copyright © 2006 Intel Corporation
45e9809aff7304721fddb95654901b32195c9c7avboxsync *
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Permission to use, copy, modify, distribute, and sell this software and its
45e9809aff7304721fddb95654901b32195c9c7avboxsync * documentation for any purpose is hereby granted without fee, provided that
45e9809aff7304721fddb95654901b32195c9c7avboxsync * the above copyright notice appear in all copies and that both that copyright
45e9809aff7304721fddb95654901b32195c9c7avboxsync * notice and this permission notice appear in supporting documentation, and
45e9809aff7304721fddb95654901b32195c9c7avboxsync * that the name of the copyright holders not be used in advertising or
45e9809aff7304721fddb95654901b32195c9c7avboxsync * publicity pertaining to distribution of the software without specific,
45e9809aff7304721fddb95654901b32195c9c7avboxsync * written prior permission. The copyright holders make no representations
45e9809aff7304721fddb95654901b32195c9c7avboxsync * about the suitability of this software for any purpose. It is provided "as
45e9809aff7304721fddb95654901b32195c9c7avboxsync * is" without express or implied warranty.
45e9809aff7304721fddb95654901b32195c9c7avboxsync *
45e9809aff7304721fddb95654901b32195c9c7avboxsync * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
45e9809aff7304721fddb95654901b32195c9c7avboxsync * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
45e9809aff7304721fddb95654901b32195c9c7avboxsync * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
45e9809aff7304721fddb95654901b32195c9c7avboxsync * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
45e9809aff7304721fddb95654901b32195c9c7avboxsync * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
45e9809aff7304721fddb95654901b32195c9c7avboxsync * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
45e9809aff7304721fddb95654901b32195c9c7avboxsync * OF THIS SOFTWARE.
45e9809aff7304721fddb95654901b32195c9c7avboxsync *
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Author: Jim Gettys, Hewlett-Packard Company, Inc.
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Keith Packard, Intel Corporation
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef HAVE_DIX_CONFIG_H
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <dix-config.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifndef _RANDRSTR_H_
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define _RANDRSTR_H_
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/X.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/Xproto.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "misc.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "os.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "dixstruct.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "resource.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "scrnintstr.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "windowstr.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "pixmapstr.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "extnsionst.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "servermd.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/extensions/randr.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/extensions/randrproto.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef RENDER
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/extensions/render.h> /* we share subpixel order information */
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "picturestr.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/Xfuncproto.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* required for ABI compatibility for now */
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define RANDR_10_INTERFACE 1
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define RANDR_12_INTERFACE 1
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef XID RRMode;
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef XID RROutput;
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef XID RRCrtc;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern int RREventBase, RRErrorBase;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern int (*ProcRandrVector[RRNumberRequests])(ClientPtr);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern int (*SProcRandrVector[RRNumberRequests])(ClientPtr);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Modeline for a monitor. Name follows directly after this struct
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define RRModeName(pMode) ((char *) (pMode + 1))
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrMode RRModeRec, *RRModePtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrPropertyValue RRPropertyValueRec, *RRPropertyValuePtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrProperty RRPropertyRec, *RRPropertyPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrCrtc RRCrtcRec, *RRCrtcPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrOutput RROutputRec, *RROutputPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncstruct _rrMode {
45e9809aff7304721fddb95654901b32195c9c7avboxsync int refcnt;
45e9809aff7304721fddb95654901b32195c9c7avboxsync xRRModeInfo mode;
45e9809aff7304721fddb95654901b32195c9c7avboxsync char *name;
45e9809aff7304721fddb95654901b32195c9c7avboxsync ScreenPtr userScreen;
45e9809aff7304721fddb95654901b32195c9c7avboxsync};
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncstruct _rrPropertyValue {
45e9809aff7304721fddb95654901b32195c9c7avboxsync Atom type; /* ignored by server */
45e9809aff7304721fddb95654901b32195c9c7avboxsync short format; /* format of data for swapping - 8,16,32 */
45e9809aff7304721fddb95654901b32195c9c7avboxsync long size; /* size of data in (format/8) bytes */
45e9809aff7304721fddb95654901b32195c9c7avboxsync pointer data; /* private to client */
45e9809aff7304721fddb95654901b32195c9c7avboxsync};
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncstruct _rrProperty {
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRPropertyPtr next;
45e9809aff7304721fddb95654901b32195c9c7avboxsync ATOM propertyName;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool is_pending;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool range;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool immutable;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int num_valid;
45e9809aff7304721fddb95654901b32195c9c7avboxsync INT32 *valid_values;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRPropertyValueRec current, pending;
45e9809aff7304721fddb95654901b32195c9c7avboxsync};
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncstruct _rrCrtc {
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtc id;
45e9809aff7304721fddb95654901b32195c9c7avboxsync ScreenPtr pScreen;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int x, y;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotations;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool changed;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numOutputs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *outputs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int gammaSize;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 *gammaRed;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 *gammaBlue;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 *gammaGreen;
45e9809aff7304721fddb95654901b32195c9c7avboxsync void *devPrivate;
45e9809aff7304721fddb95654901b32195c9c7avboxsync};
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncstruct _rrOutput {
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutput id;
45e9809aff7304721fddb95654901b32195c9c7avboxsync ScreenPtr pScreen;
45e9809aff7304721fddb95654901b32195c9c7avboxsync char *name;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int nameLength;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD8 connection;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD8 subpixelOrder;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int mmWidth;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int mmHeight;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr crtc;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numCrtcs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr *crtcs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numClones;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *clones;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numModes;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numPreferred;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr *modes;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numUserModes;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr *userModes;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool changed;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRPropertyPtr properties;
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool pendingProperties;
45e9809aff7304721fddb95654901b32195c9c7avboxsync void *devPrivate;
45e9809aff7304721fddb95654901b32195c9c7avboxsync};
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#if RANDR_12_INTERFACE
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RRScreenSetSizeProcPtr) (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 width,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 height,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD32 mmWidth,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD32 mmHeight);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RRCrtcSetProcPtr) (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr crtc,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int x,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int y,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numOutputs,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *outputs);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RRCrtcSetGammaProcPtr) (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr crtc);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RROutputSetPropertyProcPtr) (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Atom property,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRPropertyValuePtr value);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RROutputValidateModeProcPtr) (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef void (*RRModeDestroyProcPtr) (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RRGetInfoProcPtr) (ScreenPtr pScreen, Rotation *rotations);
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RRCloseScreenProcPtr) ( int i, ScreenPtr pscreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* These are for 1.0 compatibility */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrRefresh {
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 rate;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode;
45e9809aff7304721fddb95654901b32195c9c7avboxsync} RRScreenRate, *RRScreenRatePtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrScreenSize {
45e9809aff7304721fddb95654901b32195c9c7avboxsync int id;
45e9809aff7304721fddb95654901b32195c9c7avboxsync short width, height;
45e9809aff7304721fddb95654901b32195c9c7avboxsync short mmWidth, mmHeight;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int nRates;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenRatePtr pRates;
45e9809aff7304721fddb95654901b32195c9c7avboxsync} RRScreenSize, *RRScreenSizePtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef RANDR_10_INTERFACE
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef Bool (*RRSetConfigProcPtr) (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int rate,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenSizePtr pSize);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _rrScrPriv {
45e9809aff7304721fddb95654901b32195c9c7avboxsync /*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * 'public' part of the structure; DDXen fill this in
45e9809aff7304721fddb95654901b32195c9c7avboxsync * as they initialize
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync#if RANDR_10_INTERFACE
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRSetConfigProcPtr rrSetConfig;
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRGetInfoProcPtr rrGetInfo;
45e9809aff7304721fddb95654901b32195c9c7avboxsync#if RANDR_12_INTERFACE
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenSetSizeProcPtr rrScreenSetSize;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcSetProcPtr rrCrtcSet;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcSetGammaProcPtr rrCrtcSetGamma;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetPropertyProcPtr rrOutputSetProperty;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputValidateModeProcPtr rrOutputValidateMode;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModeDestroyProcPtr rrModeDestroy;
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync /*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Private part of the structure; not considered part of the ABI
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync TimeStamp lastSetTime; /* last changed by client */
45e9809aff7304721fddb95654901b32195c9c7avboxsync TimeStamp lastConfigTime; /* possible configs changed */
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCloseScreenProcPtr CloseScreen;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool changed; /* some config changed */
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool configChanged; /* configuration changed */
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool layoutChanged; /* screen layout changed */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 minWidth, minHeight;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 maxWidth, maxHeight;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 width, height; /* last known screen size */
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 mmWidth, mmHeight; /* last known screen size */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numOutputs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *outputs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numCrtcs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr *crtcs;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync /* Last known pointer position */
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr pointerCrtc;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef RANDR_10_INTERFACE
45e9809aff7304721fddb95654901b32195c9c7avboxsync /*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Configuration information
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotations;
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 reqWidth, reqHeight;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync int nSizes;
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenSizePtr pSizes;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int rate;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int size;
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync} rrScrPrivRec, *rrScrPrivPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern int rrPrivIndex;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define rrGetScrPriv(pScr) ((rrScrPrivPtr) (pScr)->devPrivates[rrPrivIndex].ptr)
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define rrScrPriv(pScr) rrScrPrivPtr pScrPriv = rrGetScrPriv(pScr)
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define SetRRScreen(s,p) ((s)->devPrivates[rrPrivIndex].ptr = (pointer) (p))
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * each window has a list of clients requesting
45e9809aff7304721fddb95654901b32195c9c7avboxsync * RRNotify events. Each client has a resource
45e9809aff7304721fddb95654901b32195c9c7avboxsync * for each window it selects RRNotify input for,
45e9809aff7304721fddb95654901b32195c9c7avboxsync * this resource is used to delete the RRNotifyRec
45e9809aff7304721fddb95654901b32195c9c7avboxsync * entry from the per-window queue.
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _RREvent *RREventPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _RREvent {
45e9809aff7304721fddb95654901b32195c9c7avboxsync RREventPtr next;
45e9809aff7304721fddb95654901b32195c9c7avboxsync ClientPtr client;
45e9809aff7304721fddb95654901b32195c9c7avboxsync WindowPtr window;
45e9809aff7304721fddb95654901b32195c9c7avboxsync XID clientResource;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int mask;
45e9809aff7304721fddb95654901b32195c9c7avboxsync} RREventRec;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _RRTimes {
45e9809aff7304721fddb95654901b32195c9c7avboxsync TimeStamp setTime;
45e9809aff7304721fddb95654901b32195c9c7avboxsync TimeStamp configTime;
45e9809aff7304721fddb95654901b32195c9c7avboxsync} RRTimesRec, *RRTimesPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _RRClient {
45e9809aff7304721fddb95654901b32195c9c7avboxsync int major_version;
45e9809aff7304721fddb95654901b32195c9c7avboxsync int minor_version;
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* RRTimesRec times[0]; */
45e9809aff7304721fddb95654901b32195c9c7avboxsync} RRClientRec, *RRClientPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern RESTYPE RRClientType, RREventType; /* resource types for event masks */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern int RRClientPrivateIndex;
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern RESTYPE RRCrtcType, RRModeType, RROutputType;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define LookupOutput(client,id,a) ((RROutputPtr) \
45e9809aff7304721fddb95654901b32195c9c7avboxsync (SecurityLookupIDByType (client, id, \
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputType, a)))
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define LookupCrtc(client,id,a) ((RRCrtcPtr) \
45e9809aff7304721fddb95654901b32195c9c7avboxsync (SecurityLookupIDByType (client, id, \
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcType, a)))
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define LookupMode(client,id,a) ((RRModePtr) \
45e9809aff7304721fddb95654901b32195c9c7avboxsync (SecurityLookupIDByType (client, id, \
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModeType, a)))
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define GetRRClient(pClient) ((RRClientPtr) (pClient)->devPrivates[RRClientPrivateIndex].ptr)
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define rrClientPriv(pClient) RRClientPtr pRRClient = GetRRClient(pClient)
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* Initialize the extension */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRExtensionInit (void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef RANDR_12_INTERFACE
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Set the range of sizes for the screen
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRScreenSetSizeRange (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 minWidth,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 minHeight,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 maxWidth,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 maxHeight);
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rrscreen.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Notify the extension that the screen size has been changed.
45e9809aff7304721fddb95654901b32195c9c7avboxsync * The driver is responsible for calling this whenever it has changed
45e9809aff7304721fddb95654901b32195c9c7avboxsync * the size of the screen
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRScreenSizeNotify (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Request that the screen be resized
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRScreenSizeSet (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 width,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 height,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD32 mmWidth,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD32 mmHeight);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Send ConfigureNotify event to root window when 'something' happens
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRSendConfigNotify (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * screen dispatch
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetScreenSizeRange (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRSetScreenSize (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetScreenResources (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRSetScreenConfig (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetScreenInfo (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Deliver a ScreenNotify event
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRDeliverScreenEvent (ClientPtr client, WindowPtr pWin, ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* mirandr.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncmiRandRInit (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncmiRRGetInfo (ScreenPtr pScreen, Rotation *rotations);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncmiRRGetScreenInfo (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncmiRRCrtcSet (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr crtc,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int x,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int y,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numOutput,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *outputs);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncmiRROutputSetProperty (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Atom property,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRPropertyValuePtr value);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncmiRROutputValidateMode (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncmiRRModeDestroy (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* randr.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Send all pending events
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRTellChanged (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Poll the driver for changed information
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRGetInfo (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool RRInit (void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool RRScreenInit(ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputPtr
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRFirstOutput (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRotation
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRGetRotation (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncCARD16
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRVerticalRefresh (xRRModeInfo *mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef RANDR_10_INTERFACE
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * This is the old interface, deprecated but left
45e9809aff7304721fddb95654901b32195c9c7avboxsync * around for compatibility
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Then, register the specific size with the screen
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRScreenSizePtr
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRRegisterSize (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync short width,
45e9809aff7304721fddb95654901b32195c9c7avboxsync short height,
45e9809aff7304721fddb95654901b32195c9c7avboxsync short mmWidth,
45e9809aff7304721fddb95654901b32195c9c7avboxsync short mmHeight);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool RRRegisterRate (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenSizePtr pSize,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int rate);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Finally, set the current configuration of the screen
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRSetCurrentConfig (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int rate,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenSizePtr pSize);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool RRScreenInit (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRotation
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRGetRotation (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRSetScreenConfig (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int rate,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenSizePtr pSize);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rrcrtc.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Notify the CRTC of some change; layoutChanged indicates that
45e9809aff7304721fddb95654901b32195c9c7avboxsync * some position or size element changed
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcChanged (RRCrtcPtr crtc, Bool layoutChanged);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Create a CRTC
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcPtr
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcCreate (ScreenPtr pScreen, void *devPrivate);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Set the allowed rotations on a CRTC
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcSetRotations (RRCrtcPtr crtc, Rotation rotations);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Notify the extension that the Crtc has been reconfigured,
45e9809aff7304721fddb95654901b32195c9c7avboxsync * the driver calls this whenever it has updated the mode
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcNotify (RRCrtcPtr crtc,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int x,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int y,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numOutputs,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *outputs);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRDeliverCrtcEvent (ClientPtr client, WindowPtr pWin, RRCrtcPtr crtc);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Request that the Crtc be reconfigured
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcSet (RRCrtcPtr crtc,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int x,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int y,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Rotation rotation,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numOutput,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *outputs);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Request that the Crtc gamma be changed
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcGammaSet (RRCrtcPtr crtc,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 *red,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 *green,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD16 *blue);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Notify the extension that the Crtc gamma has been changed
45e9809aff7304721fddb95654901b32195c9c7avboxsync * The driver calls this whenever it has changed the gamma values
45e9809aff7304721fddb95654901b32195c9c7avboxsync * in the RRCrtcRec
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcGammaNotify (RRCrtcPtr crtc);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Set the size of the gamma table at server startup time
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcGammaSetSize (RRCrtcPtr crtc,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int size);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Return the area of the frame buffer scanned out by the crtc,
45e9809aff7304721fddb95654901b32195c9c7avboxsync * taking into account the current mode and rotation
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcGetScanoutSize(RRCrtcPtr crtc, int *width, int *height);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Destroy a Crtc at shutdown
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcDestroy (RRCrtcPtr crtc);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Initialize crtc type
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRCrtcInit (void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Crtc dispatch
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetCrtcInfo (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRSetCrtcConfig (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetCrtcGammaSize (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetCrtcGamma (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRSetCrtcGamma (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rrdispatch.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRClientKnowsRates (ClientPtr pClient);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rrmode.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Find, and if necessary, create a mode
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRModePtr
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRModeGet (xRRModeInfo *modeInfo,
45e9809aff7304721fddb95654901b32195c9c7avboxsync const char *name);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRModePruneUnused (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Destroy a mode.
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRModeDestroy (RRModePtr mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Return a list of modes that are valid for some output in pScreen
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRModePtr *
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRModesForScreen (ScreenPtr pScreen, int *num_ret);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Initialize mode type
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRModeInit (void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRCreateMode (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRDestroyMode (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRAddOutputMode (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRDeleteOutputMode (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rroutput.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Notify the output of some change. configChanged indicates whether
45e9809aff7304721fddb95654901b32195c9c7avboxsync * any external configuration (mode list, clones, connected status)
45e9809aff7304721fddb95654901b32195c9c7avboxsync * has changed, or whether the change was strictly internal
45e9809aff7304721fddb95654901b32195c9c7avboxsync * (which crtc is in use)
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputChanged (RROutputPtr output, Bool configChanged);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Create an output
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputPtr
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputCreate (ScreenPtr pScreen,
45e9809aff7304721fddb95654901b32195c9c7avboxsync const char *name,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int nameLength,
45e9809aff7304721fddb95654901b32195c9c7avboxsync void *devPrivate);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Notify extension that output parameters have been changed
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputSetClones (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputPtr *clones,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numClones);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputSetModes (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr *modes,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numModes,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numPreferred);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputAddUserMode (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputDeleteUserMode (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModePtr mode);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputSetCrtcs (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcPtr *crtcs,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int numCrtcs);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputSetConnection (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CARD8 connection);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputSetSubpixelOrder (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int subpixelOrder);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputSetPhysicalSize (RROutputPtr output,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int mmWidth,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int mmHeight);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRDeliverOutputEvent(ClientPtr client, WindowPtr pWin, RROutputPtr output);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputDestroy (RROutputPtr output);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetOutputInfo (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * Initialize output type
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRROutputInit (void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rrpointer.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRPointerMoved (ScreenPtr pScreen, int x, int y);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRPointerScreenConfigured (ScreenPtr pScreen);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rrproperty.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRDeleteAllOutputProperties (RROutputPtr output);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRPropertyValuePtr
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRGetOutputProperty (RROutputPtr output, Atom property, Bool pending);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRPropertyPtr
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRQueryOutputProperty (RROutputPtr output, Atom property);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRDeleteOutputProperty (RROutputPtr output, Atom property);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncBool
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRPostPendingProperties (RROutputPtr output);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRChangeOutputProperty (RROutputPtr output, Atom property, Atom type,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int format, int mode, unsigned long len,
45e9809aff7304721fddb95654901b32195c9c7avboxsync pointer value, Bool sendevent, Bool pending);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRConfigureOutputProperty (RROutputPtr output, Atom property,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool pending, Bool range, Bool immutable,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int num_values, INT32 *values);
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRChangeOutputProperty (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRGetOutputProperty (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRListOutputProperties (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRQueryOutputProperty (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRConfigureOutputProperty (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncint
45e9809aff7304721fddb95654901b32195c9c7avboxsyncProcRRDeleteOutputProperty (ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* rrxinerama.c */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncvoid
45e9809aff7304721fddb95654901b32195c9c7avboxsyncRRXineramaExtensionInit(void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif /* _RANDRSTR_H_ */
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncrandr extension implementation structure
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncQuery state:
45e9809aff7304721fddb95654901b32195c9c7avboxsync ProcRRGetScreenInfo/ProcRRGetScreenResources
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRGetInfo
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync • Request configuration from driver, either 1.0 or 1.2 style
45e9809aff7304721fddb95654901b32195c9c7avboxsync • These functions only record state changes, all
45e9809aff7304721fddb95654901b32195c9c7avboxsync other actions are pended until RRTellChanged is called
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync ->rrGetInfo
45e9809aff7304721fddb95654901b32195c9c7avboxsync 1.0:
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRRegisterSize
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRRegisterRate
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRSetCurrentConfig
45e9809aff7304721fddb95654901b32195c9c7avboxsync 1.2:
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScreenSetSizeRange
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetCrtcs
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModeGet
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetModes
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetConnection
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetSubpixelOrder
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetClones
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcNotify
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync • Must delay scanning configuration until after ->rrGetInfo returns
45e9809aff7304721fddb95654901b32195c9c7avboxsync because some drivers will call SetCurrentConfig in the middle
45e9809aff7304721fddb95654901b32195c9c7avboxsync of the ->rrGetInfo operation.
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync 1.0:
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync • Scan old configuration, mirror to new structures
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRScanOldConfig
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcCreate
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputCreate
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetCrtcs
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetConnection
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROutputSetSubpixelOrder
45e9809aff7304721fddb95654901b32195c9c7avboxsync RROldModeAdd • This adds modes one-at-a-time
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRModeGet
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcNotify
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync • send events, reset pointer if necessary
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRTellChanged
45e9809aff7304721fddb95654901b32195c9c7avboxsync WalkTree (sending events)
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync • when layout has changed:
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRPointerScreenConfigured
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRSendConfigNotify
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncAsynchronous state setting (1.2 only)
45e9809aff7304721fddb95654901b32195c9c7avboxsync When setting state asynchronously, the driver invokes the
45e9809aff7304721fddb95654901b32195c9c7avboxsync ->rrGetInfo function and then calls RRTellChanged to flush
45e9809aff7304721fddb95654901b32195c9c7avboxsync the changes to the clients and reset pointer if necessary
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSet state
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync ProcRRSetScreenConfig
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcSet
45e9809aff7304721fddb95654901b32195c9c7avboxsync 1.2:
45e9809aff7304721fddb95654901b32195c9c7avboxsync ->rrCrtcSet
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcNotify
45e9809aff7304721fddb95654901b32195c9c7avboxsync 1.0:
45e9809aff7304721fddb95654901b32195c9c7avboxsync ->rrSetConfig
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRCrtcNotify
45e9809aff7304721fddb95654901b32195c9c7avboxsync RRTellChanged
45e9809aff7304721fddb95654901b32195c9c7avboxsync */