diff options
| author | Ville Syrjälä <[email protected]> | 2013-04-24 18:52:35 +0300 |
|---|---|---|
| committer | Daniel Vetter <[email protected]> | 2013-04-30 22:19:39 +0200 |
| commit | 4954c4282f6b945f1dd5716f92b594a07fa4ffe3 (patch) | |
| tree | 3c72d5bd093e1c066cd1ef8c0f9608231ad4d44f /tools/perf/scripts/python/bin | |
| parent | 3512f976d252bd5d07d04e9e157f0cd210c959a0 (diff) | |
drm: Add drm_rect_calc_{hscale, vscale}() utility functions
These functions calculate the scaling factor based on the source and
destination rectangles.
There are two version of the functions, the strict ones that will
return an error if the min/max scaling factor is exceeded, and the
relaxed versions that will adjust the src/dst rectangles in order to
keep the scaling factor withing the limits.
v2: Return error instead of adjusting regions, refactor common parts
into one function, and split into strict and relaxed versions.
v3: Renamed drm_region to drm_rect, add "_rect_" to the function
names.
v4: Fix "calculcate" typos
Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Ville Syrjälä <[email protected]>
Acked-by: Dave Airlie <[email protected]>
Signed-off-by: Daniel Vetter <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions