diff options
author | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2019-06-28 20:44:15 +0300 |
---|---|---|
committer | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2019-07-08 16:32:53 +0300 |
commit | 0e2045f533387bc41bc78957109262f1192b8adb (patch) | |
tree | 405541126dceaf002bcb17e64477780fe155b957 /tests | |
parent | d2a10fb734c34b72eb17c58d9dae813321112ee6 (diff) |
lib/igt_fb: Allow creating yuv fbs with different encodings/ranges
Pass the color encoding/range to igt_create_fb_with_bo_size()
so that tests are able to generate fbs with various encodings/ranges.
v2: Drop the _full() variants of th fb create funcs (Nicholas)
Cc: Uma Shankar <uma.shankar@intel.com>
Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com> #v1
Reviewed-by: Uma Shankar <uma.shankar@intel.com> #v1
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/kms_flip.c | 6 | ||||
-rw-r--r-- | tests/kms_frontbuffer_tracking.c | 6 |
2 files changed, 8 insertions, 4 deletions
diff --git a/tests/kms_flip.c b/tests/kms_flip.c index 0a8d1c55..ef2521f2 100755 --- a/tests/kms_flip.c +++ b/tests/kms_flip.c @@ -1247,8 +1247,10 @@ static void run_test_on_crtc_set(struct test_output *o, int *crtc_idxs, igt_bpp_depth_to_drm_format(o->bpp, o->depth), tiling, &o->fb_info[0]); o->fb_ids[1] = igt_create_fb_with_bo_size(drm_fd, o->fb_width, o->fb_height, - igt_bpp_depth_to_drm_format(o->bpp, o->depth), - tiling, &o->fb_info[1], bo_size, 0); + igt_bpp_depth_to_drm_format(o->bpp, o->depth), + tiling, IGT_COLOR_YCBCR_BT709, + IGT_COLOR_YCBCR_LIMITED_RANGE, + &o->fb_info[1], bo_size, 0); igt_assert(o->fb_ids[0]); igt_assert(o->fb_ids[1]); diff --git a/tests/kms_frontbuffer_tracking.c b/tests/kms_frontbuffer_tracking.c index 1037faf8..c788b59e 100644 --- a/tests/kms_frontbuffer_tracking.c +++ b/tests/kms_frontbuffer_tracking.c @@ -491,8 +491,10 @@ static void create_fb(enum pixel_format pformat, int width, int height, igt_calc_fb_size(drm.fd, width, height, format, tiling_for_size, &size, &stride); - igt_create_fb_with_bo_size(drm.fd, width, height, format, tiling, fb, - size, stride); + igt_create_fb_with_bo_size(drm.fd, width, height, format, tiling, + IGT_COLOR_YCBCR_BT709, + IGT_COLOR_YCBCR_LIMITED_RANGE, + fb, size, stride); } static uint32_t pick_color(struct igt_fb *fb, enum color ecolor) |