diff options
author | Dave Airlie <airlied@redhat.com> | 2012-01-20 17:40:10 +0000 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2012-07-19 13:12:48 +1000 |
commit | 5d2edde0bf8460aab250dd83743aedb5c66a243e (patch) | |
tree | b35d67c73783dedcf3e32ffe22c531f3115e534a /include/X11/extensions/Xrandr.h | |
parent | a9457b44539420c0b7a082ef6ecc5fd3391e8801 (diff) |
libXrandr: add support for provider objects.
This adds the client side libXrandr support for randr 1.4,
and provider objects.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'include/X11/extensions/Xrandr.h')
-rw-r--r-- | include/X11/extensions/Xrandr.h | 101 |
1 files changed, 101 insertions, 0 deletions
diff --git a/include/X11/extensions/Xrandr.h b/include/X11/extensions/Xrandr.h index 4b29c3f..b1baf8a 100644 --- a/include/X11/extensions/Xrandr.h +++ b/include/X11/extensions/Xrandr.h @@ -39,6 +39,7 @@ _XFUNCPROTOBEGIN typedef XID RROutput; typedef XID RRCrtc; typedef XID RRMode; +typedef XID RRProvider; typedef struct { int width, height; @@ -118,6 +119,41 @@ typedef struct { int state; /* NewValue, Deleted */ } XRROutputPropertyNotifyEvent; +typedef struct { + int type; /* event base */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* window which selected for this event */ + int subtype; /* RRNotify_ProviderChange */ + RRProvider provider; /* current provider (or None) */ + Time timestamp; /* time of change */ + unsigned int current_role; +} XRRProviderChangeNotifyEvent; + +typedef struct { + int type; /* event base */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* window which selected for this event */ + int subtype; /* RRNotify_ProviderProperty */ + RRProvider provider; /* related provider */ + Atom property; /* changed property */ + Time timestamp; /* time of change */ + int state; /* NewValue, Deleted */ +} XRRProviderPropertyNotifyEvent; + +typedef struct { + int type; /* event base */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* window which selected for this event */ + int subtype; /* RRNotify_ResourceChange */ + Time timestamp; /* time of change */ +} XRRResourceChangeNotifyEvent; + /* internal representation is private to the library */ typedef struct _XRRScreenConfiguration XRRScreenConfiguration; @@ -451,6 +487,71 @@ RROutput XRRGetOutputPrimary(Display *dpy, Window window); +typedef struct _XRRProviderResources { + Time timestamp; + int nproviders; + RRProvider *providers; +} XRRProviderResources; + +XRRProviderResources * +XRRGetProviderResources(Display *dpy, Window window); + +void +XRRFreeProviderResources(XRRProviderResources *resources); + +typedef struct _XRRProviderInfo { + unsigned int capabilities; + int ncrtcs; + RRCrtc *crtcs; + int noutputs; + RROutput *outputs; + char *name; + int nassociatedproviders; + RRProvider *associated_providers; + unsigned int *associated_capability; + int nameLen; +} XRRProviderInfo; + +XRRProviderInfo * +XRRGetProviderInfo(Display *dpy, XRRScreenResources *resources, RRProvider provider); + +void +XRRFreeProviderInfo(XRRProviderInfo *provider); + +int +XRRSetProviderOutputSource(Display *dpy, XID provider, XID source_provider); + +int +XRRSetProviderOffloadSink(Display *dpy, XID provider, XID sink_provider); + +Atom * +XRRListProviderProperties (Display *dpy, RRProvider provider, int *nprop); + +XRRPropertyInfo * +XRRQueryProviderProperty (Display *dpy, RRProvider provider, Atom property); + +void +XRRConfigureProviderProperty (Display *dpy, RRProvider provider, Atom property, + Bool pending, Bool range, int num_values, + long *values); + +void +XRRChangeProviderProperty (Display *dpy, RRProvider provider, + Atom property, Atom type, + int format, int mode, + _Xconst unsigned char *data, int nelements); + +void +XRRDeleteProviderProperty (Display *dpy, RRProvider provider, Atom property); + +int +XRRGetProviderProperty (Display *dpy, RRProvider provider, + Atom property, long offset, long length, + Bool _delete, Bool pending, Atom req_type, + Atom *actual_type, int *actual_format, + unsigned long *nitems, unsigned long *bytes_after, + unsigned char **prop); + _XFUNCPROTOEND #endif /* _XRANDR_H_ */ |