compositor: Move weston_matrix_transform_region to compositor.c and export it

We're going to use this to replace much of the other transform code so
it's no longer just relevant to pixman-renderer.c
compositor: add weston_matrix_transform_rect() and use it for weston_matrix_transform_region()

New function that transforms a pixman_box32_t rectangle by a matrix.

Since pixman rectangles are represented by 2 corners, non-90 degree
rotations can't be properly represented.  This function gives the
axis aligned rectangle that encloses the rotated rectangle.

This simplifies weston_matrix_transform_region() and allows it to work for
non-90 degree rotations.
compositor: use matrix transforms for surface_to_buffer functions

Now that we have weston_matrix_transform and appropriate matrices we can
use that instead of weston_transformed_coord + scaler_surface_to_buffer.

scaler_surface_to_buffer no longer has users, so remove it.
compositor: use weston_matrix_transform_rect for weston_surface_to_buffer_rect
compositor: use weston_matrix_transform_region for overlay setup
compositor: Remove weston_transformed_region

Replace all uses of weston_transform_region with
weston_matrix_transform_region, then remove the function completely.
matrix: Add functions to decompose a transformation matrix into basic operations

Adds an internal weston_matrix_decompose() which takes a matrix and decomposes
translation, rotation, shear and scale parameters to re-create it.

This information is cached the first time any helper functions are used to extract
these values and dirtied whenever a matrix multiplication takes place.

Note that these may not be the same values used to compose the matrix in the first
place.
compositor: Add a function to test if images transformed by a matrix should be bilinearly filtered

If a transformation matrix causes a scale or a rotation not a multiple of 90
degrees then textures rendered with it would benefit from bilinear filtering.

weston_matrix_needs_filtering() checks for this.
renderers: use weston_matrix_needs_filtering to choose filter parameters in gl and pixman renderers

Note: This causes a performance drop when zoomed under pixman.
compositor-drm: use weston_surface_to_buffer_rect instead of weston_transformed_rect

The weston_transformed_rect() call should have the same result as
weston_surface_to_buffer_rect().

Also, this mix of fixed, float, and int is difficult to follow and I don't
trust it, so just convert to fixed for the plane API at the end of the
calculation.
compositor: Remove weston_transformed_rect() and weston_transformed_coord()

The last caller of weston_transformed_rect() has been replaced so we can
remove weston_transformed_rect() - since it was the last called of
weston_transformed_coord() we can get rid of that too.