diff options
author | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2014-07-08 10:31:55 +0530 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-07-11 23:44:12 +0200 |
commit | 07074006cd951f7a952512c57d60788ee7ea18db (patch) | |
tree | 9ddc3b8eda1f941782f09adfdd0a30658c2720b1 /include/drm | |
parent | a4969dd78735ea61bf67712987e1bd69d32e243c (diff) | |
download | op-kernel-dev-07074006cd951f7a952512c57d60788ee7ea18db.zip op-kernel-dev-07074006cd951f7a952512c57d60788ee7ea18db.tar.gz |
drm: Add drm_rect rotation functions
Add some helper functions to move drm_rects between different rotated
coordinate spaces. One function does the forward transform and
another does the inverse.
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Imre Deak <imre.deak@intel.com>
Acked-by: Dave Airlie <airlied@linux.ie>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'include/drm')
-rw-r--r-- | include/drm/drm_rect.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/drm/drm_rect.h b/include/drm/drm_rect.h index d128629..26bb55e 100644 --- a/include/drm/drm_rect.h +++ b/include/drm/drm_rect.h @@ -163,5 +163,11 @@ int drm_rect_calc_vscale_relaxed(struct drm_rect *src, struct drm_rect *dst, int min_vscale, int max_vscale); void drm_rect_debug_print(const struct drm_rect *r, bool fixed_point); +void drm_rect_rotate(struct drm_rect *r, + int width, int height, + unsigned int rotation); +void drm_rect_rotate_inv(struct drm_rect *r, + int width, int height, + unsigned int rotation); #endif |