[PATCH v5 xserver 5/7] xf86Cursor: Fix xf86_crtc_rotate_coord_back using width/height wrongly

Michel Dänzer michel at daenzer.net
Wed Sep 7 01:21:55 UTC 2016


On 06/09/16 08:31 PM, Hans De Goede wrote:
> xf86_crtc_rotate_coord_back should be the exact inverse operation of
> xf86_crtc_rotate_coord, but when calculating x / y for 90 / 270 degrees
> rotation it was using height to calculate x / width to calculate y,
> instead of the otherway around.

I think it's correct as is. It's certainly symmetrical with
xf86_crtc_rotate_coord.


> This was likely not noticed before since xf86_crtc_rotate_coord_back
> until now was only used with cursor_info->MaxWidth and
> cursor_info->MaxHeight, which are usally the same.

I'd say it's kind of the other way around:
xf86_crtc_transform_cursor_position just happens to still work with your
change because usually cursor_info->MaxWidth == cursor_info->MaxHeight .


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


More information about the xorg-devel mailing list