[PATCH libinput 1/2] Document LIBINPUT_CALIBRATION_MATRIX properly

Bill Spitzak spitzak at gmail.com
Tue Sep 9 18:14:05 PDT 2014


On 09/09/2014 04:40 PM, Peter Hutterer wrote:

> + * The udev property is parsed as 6 floating point numbers separated by a
> + * single space each (scanf(3) format "%f %f %f %f %f %f").
> + * The 6 values represent the first two rows of the calibration matrix as
> + * described in libinput_device_config_calibration_set_matrix().

Six-entry affine matricies are more commonly done as columns, such that 
the list (a,b,c,d,x,y) describes the following matrix:

	| a c x |
	| b d y |
	| 0 0 1 |

This is used by Cairo and PostScript, and probably by SVG and anything 
else influenced by PostScript.

You are describing (a,c,x,b,d,y). This is not often used because of the 
unexpected splitting of x,y.

Unfortunately I have also seen (a,c,b,d,x,y). Don't do that...

If it is possible to change this now without breaking any existing code 
it may be a good idea.


More information about the wayland-devel mailing list