summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorVille Syrjälä <ville.syrjala@linux.intel.com>2018-02-27 22:57:16 +0200
committerVille Syrjälä <ville.syrjala@linux.intel.com>2018-06-08 12:56:01 +0300
commit8790756018b41423366435c6d69fc41d578d494e (patch)
tree1371ab2698f65bdf7005d9e37b1c4950db11724d /lib
parente867d65b7161b75dcbabb56677577c04aa52feb7 (diff)
lib: Don't use dumb buffers for YCbCr
We don't do the "black != zero" clearing for dumb buffers, so let's not use them for YCbCr framebuffers. v2: Use igt_format_is_yuv() Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/igt_fb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index 01936dd7..1dfa958a 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -350,7 +350,7 @@ static int create_bo_for_fb(int fd, int width, int height,
if (offsets)
memset(offsets, 0, ARRAY_SIZE(format->plane_bpp) * sizeof(*offsets));
- if (tiling || size || stride || format->planes > 1) {
+ if (tiling || size || stride || igt_format_is_yuv(format->drm_id)) {
unsigned calculated_size, calculated_stride;
if (format->planes > 1)