summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2008-03-18 16:02:36 -0700
committerKeith Packard <keithp@keithp.com>2008-03-18 16:02:36 -0700
commit7a21e7bc994c5fa7d3ab15ba7201667e134f1512 (patch)
tree3bf25d6c81fea734c15bcc8387af372b3164e782
parenta6e5fa4ceb72795380496fcfe62c083866791dc1 (diff)
Eliminate inverse matrix from randr transform protocol
It is easier, and potentially more precise, to compute the inverse in the server where everything can eventually be kept in floating point form.
-rw-r--r--include/X11/extensions/Xrandr.h3
-rw-r--r--src/XrrCrtc.c8
2 files changed, 0 insertions, 11 deletions
diff --git a/include/X11/extensions/Xrandr.h b/include/X11/extensions/Xrandr.h
index 32171f9..de18f3b 100644
--- a/include/X11/extensions/Xrandr.h
+++ b/include/X11/extensions/Xrandr.h
@@ -378,19 +378,16 @@ void
XRRSetCrtcTransform (Display *dpy,
RRCrtc crtc,
XTransform *transform,
- XTransform *inverse,
char *filter,
XFixed *params,
int nparams);
typedef struct _XRRCrtcTransformAttributes {
XTransform pendingTransform;
- XTransform pendingInverse;
char *pendingFilter;
int pendingNparams;
XFixed *pendingParams;
XTransform currentTransform;
- XTransform currentInverse;
char *currentFilter;
int currentNparams;
XFixed *currentParams;
diff --git a/src/XrrCrtc.c b/src/XrrCrtc.c
index 8bca1b1..a1d92cb 100644
--- a/src/XrrCrtc.c
+++ b/src/XrrCrtc.c
@@ -311,7 +311,6 @@ void
XRRSetCrtcTransform (Display *dpy,
RRCrtc crtc,
XTransform *transform,
- XTransform *inverse,
char *filter,
XFixed *params,
int nparams)
@@ -329,7 +328,6 @@ XRRSetCrtcTransform (Display *dpy,
req->crtc = crtc;
xRenderTransform_from_XTransform (&req->transform, transform);
- xRenderTransform_from_XTransform (&req->inverse, inverse);
req->nbytesFilter = nbytes;
req->length += ((nbytes + 3) >> 2) + nparams;
@@ -377,11 +375,9 @@ XRRGetCrtcTransform (Display *dpy,
{
/* For pre-1.3 servers, just report identity matrices everywhere */
rep.pendingTransform = identity;
- rep.pendingInverse = identity;
rep.pendingNbytesFilter = 0;
rep.pendingNparamsFilter = 0;
rep.currentTransform = identity;
- rep.currentInverse = identity;
rep.currentNbytesFilter = 0;
rep.currentNparamsFilter = 0;
}
@@ -396,11 +392,9 @@ XRRGetCrtcTransform (Display *dpy,
if (!_XReply (dpy, (xReply *) &rep, CrtcTransformExtra >> 2, xFalse))
{
rep.pendingTransform = identity;
- rep.pendingInverse = identity;
rep.pendingNbytesFilter = 0;
rep.pendingNparamsFilter = 0;
rep.currentTransform = identity;
- rep.currentInverse = identity;
rep.currentNbytesFilter = 0;
rep.currentNparamsFilter = 0;
}
@@ -432,9 +426,7 @@ XRRGetCrtcTransform (Display *dpy,
return False;
}
XTransform_from_xRenderTransform (&attr->pendingTransform, &rep.pendingTransform);
- XTransform_from_xRenderTransform (&attr->pendingInverse, &rep.pendingInverse);
XTransform_from_xRenderTransform (&attr->currentTransform, &rep.currentTransform);
- XTransform_from_xRenderTransform (&attr->currentInverse, &rep.currentInverse);
attr->pendingParams = (XFixed *) (attr + 1);
attr->currentParams = attr->pendingParams + rep.pendingNparamsFilter;