[Mesa-stable] [Mesa-dev] [PATCH] egl/wayland: Don't use DRM format codes for SHM

Daniel Stone daniel at fooishbar.org
Wed Mar 1 14:13:19 UTC 2017


Hi Emil,

On 15 February 2017 at 12:23, Emil Velikov <emil.l.velikov at gmail.com> wrote:
> On 13 February 2017 at 17:54, Daniel Stone <daniel at fooishbar.org> wrote:
>>> From a quick look shm_handle_format() comes to mind. Keep in mind that
>>> I'm not that big of an expert on the Wayland code so I might have
>>> missed something ;-)
>>
>> Oh, that's fine. shm_handle_format (and drm_handle_format, for
>> non-swrast) gets called to handle events coming in from the server
>> side. So we will receive WL_SHM_FORMAT_* (not WL_DRM_FORMAT_*) from
>> the wire, and use that to set enum values which are constant between
>> SHM and DRM. So I don't see the problem with that.
>>
> Storing a DRM format only to convert it to SHM one does sound like a
> problem waiting to happen. But if you prefer so I won't object.

Indeed it is a little strange, but it was the least invasive solution,
and seems like something we could clean up if/when it came to adding
more formats. Do you think it's worth pushing?

Cheers,
Daniel


More information about the mesa-stable mailing list