Eric Piel (none) eric at triangle.
Sat Jan 2 15:40:19 PST 2010

```Add information about the transformation, stating it's a homogeneous
coordinate transformation, with formula provided by Bernard Siaud, and
an example of keystone shaping generated using the algorithm found in
xkeystone.

Signed-off-by: Eric Piel <eric.piel at tremplin-utc.net>
---
xrandr.man |   36 +++++++++++++++++++++++++++++-------
1 files changed, 29 insertions(+), 7 deletions(-)

diff --git a/xrandr.man b/xrandr.man
index 1fceeb6..cbc8049 100644
--- a/xrandr.man
+++ b/xrandr.man
@@ -158,13 +158,29 @@ d e f
.br
g h i
.RE
-The transformation matrix multiplied by a coordinate vector of a pixel of the
-output (extended to 3 values) gives the approximate coordinate vector of a pixel
-in the graphic buffer. Typically, \fIa\fP and
+The transformation is based on homogeneous coordinates. The matrix multiplied
+by the coordinate vector of a pixel of the output gives the approximate
+coordinate vector of a pixel in the graphic buffer.  More precisely, the vector
+of the output pixel is extended to 3 values, with 1 as the Z coordinate, and
+the final vector of the buffer pixel is scaled so that its Z coordinate is 1.
+In other words, the coordinates of the buffer pixel are:
+.RS
+ (a b)(x)+(c)
+.br
+ (d e)(y) (f)
+.br
+â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€
+.br
+((g h)(x)+1)Â·i
+.br
+      (y)
+.RE
+Typically, \fIa\fP and
\fIe\fP corresponds to the scaling on the X and Y axes, \fIc\fP and \fIf\fP
-corresponds to the tranlastion on those axes, and \fIg\fP, \fIh\fP, and \fIi\fP
-are respectively 0, 0 and 1. It also allows to express a rotation of an angle T
-with:
+corresponds to the translation on those axes, and \fIg\fP, \fIh\fP, and \fIi\fP
+are respectively 0, 0 and 1. The matrix can also be used to express more
+complex transformations such as keystone shaping, or rotation.  For a
+rotation of an angle T, this formula can be used:
.RS
cos T  -sin T   0
.br
@@ -313,8 +329,14 @@ big VGA screen display the surrounding of the mouse at normal size.
.RS
xrandr --fb 3200x2000 --output LVDS --scale 2.5x2.5 --output VGA --pos 0x0 --panning 3200x2000+0+0/3200x2000+0+0/64/64/64/64
.RE
+.PP
+Displays the VGA output in keystone shape so that it is projected correctly
+when the beamer is slightly above the screen:
+.RS
+xrandr --fb 1024x768 --output VGA --transform 1.24,0.16,-124,0,1.24,0,0,0.000316,1
+.RE
-Xrandr(3), cvt(1)
+Xrandr(3), cvt(1), xkeystone(1)
.SH AUTHORS
Keith Packard,
Open Source Technology Center, Intel Corporation.
--
1.6.6

--------------040705000802060107030004--
```