ozone/wayland: do not use modifiers for linear buffers

Video playback is broken in Ozone/Wayland whenever Wayland compositor
announces that R_8 buffer is supported and sends supported format
modifiers for that buffer type.

Then, when video is played, GbmPixmapWayland is created with format
modifiers supplied by Wayland compositor. However, this result in a video
playback that is garbled.

The reason to this is that the buffer is requested to be linear, which
means no format modifiers should be supplied. I believe it could be
the gbm handling that, but it turns out that messes up and we have
weird behaviour.

Thus, do not use format modifiers if the buffer usage is linear.

Bug: 1050364
Change-Id: I980c462f857b3a462f95677810e3ff2aaaf340c6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2049978
Reviewed-by: Michael Spang <spang@chromium.org>
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Commit-Queue: Maksim Sisov <msisov@igalia.com>
Cr-Commit-Position: refs/heads/master@{#742670}
1 file changed