randr: Crtc interface update for panning support.
This commit is contained in:
		
							parent
							
								
									a475eb9fee
								
							
						
					
					
						commit
						834cbc16f3
					
				| 
						 | 
					@ -213,9 +213,16 @@ typedef struct _xf86CrtcFuncs {
 | 
				
			||||||
    Bool
 | 
					    Bool
 | 
				
			||||||
    (*set_mode_major)(xf86CrtcPtr crtc, DisplayModePtr mode,
 | 
					    (*set_mode_major)(xf86CrtcPtr crtc, DisplayModePtr mode,
 | 
				
			||||||
		      Rotation rotation, int x, int y);
 | 
							      Rotation rotation, int x, int y);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * Callback for panning. Doesn't change the mode.
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
 | 
					    void
 | 
				
			||||||
 | 
					    (*pan)(xf86CrtcPtr crtc, int x, int y);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
} xf86CrtcFuncsRec, *xf86CrtcFuncsPtr;
 | 
					} xf86CrtcFuncsRec, *xf86CrtcFuncsPtr;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#define XF86_CRTC_VERSION 1
 | 
					#define XF86_CRTC_VERSION 2
 | 
				
			||||||
 | 
					
 | 
				
			||||||
struct _xf86Crtc {
 | 
					struct _xf86Crtc {
 | 
				
			||||||
    /**
 | 
					    /**
 | 
				
			||||||
| 
						 | 
					@ -321,6 +328,15 @@ struct _xf86Crtc {
 | 
				
			||||||
     * Bounding box in screen space
 | 
					     * Bounding box in screen space
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    BoxRec	    bounds;
 | 
					    BoxRec	    bounds;
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * Panning:
 | 
				
			||||||
 | 
					     * TotalArea: total panning area, larger than CRTC's size
 | 
				
			||||||
 | 
					     * TrackingArea: Area of the pointer for which the CRTC is panned
 | 
				
			||||||
 | 
					     * border: Borders of the displayed CRTC area which induces panning if the pointer reaches them
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
 | 
					    BoxRec          panningTotalArea;
 | 
				
			||||||
 | 
					    BoxRec          panningTrackingArea;
 | 
				
			||||||
 | 
					    INT16           panningBorder[4];
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
typedef struct _xf86OutputFuncs {
 | 
					typedef struct _xf86OutputFuncs {
 | 
				
			||||||
| 
						 | 
					@ -678,6 +694,9 @@ extern _X_EXPORT Bool
 | 
				
			||||||
xf86CrtcSetMode (xf86CrtcPtr crtc, DisplayModePtr mode, Rotation rotation,
 | 
					xf86CrtcSetMode (xf86CrtcPtr crtc, DisplayModePtr mode, Rotation rotation,
 | 
				
			||||||
		 int x, int y);
 | 
							 int x, int y);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					void
 | 
				
			||||||
 | 
					xf86CrtcPan (xf86CrtcPtr crtc, int x, int y);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/*
 | 
					/*
 | 
				
			||||||
 * Assign crtc rotation during mode set
 | 
					 * Assign crtc rotation during mode set
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
| 
						 | 
					@ -868,4 +887,19 @@ xf86_unwrap_crtc_notify(ScreenPtr pScreen, xf86_crtc_notify_proc_ptr old);
 | 
				
			||||||
extern _X_EXPORT void
 | 
					extern _X_EXPORT void
 | 
				
			||||||
xf86_crtc_notify(ScreenPtr pScreen);
 | 
					xf86_crtc_notify(ScreenPtr pScreen);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					/**
 | 
				
			||||||
 | 
					 * Panning
 | 
				
			||||||
 | 
					 */
 | 
				
			||||||
 | 
					Bool
 | 
				
			||||||
 | 
					xf86_crtc_get_panning(ScrnInfoPtr pScrn,
 | 
				
			||||||
 | 
							      BoxPtr      totalArea,
 | 
				
			||||||
 | 
							      BoxPtr      TrackingArea,
 | 
				
			||||||
 | 
							      INT16      *border);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Bool
 | 
				
			||||||
 | 
					xf86_crtc_set_panning(ScrnInfoPtr pScrn,
 | 
				
			||||||
 | 
							      BoxPtr      totalArea,
 | 
				
			||||||
 | 
							      BoxPtr      TrackingArea,
 | 
				
			||||||
 | 
							      INT16      *border);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#endif /* _XF86CRTC_H_ */
 | 
					#endif /* _XF86CRTC_H_ */
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue