Skip to contentSkip to conversation

VKMS: New plane formats

DISCUSSION Igor Matheus Andrade Torrente 2 participants 3 messages Sep 1, 2021 – Sep 2, 2021

lore
Share & tools
lore
#0 lore raw

Hi,

I'm working to add new plane formats to vkms. But I don't know what should be the behavior in the situation that we received multiple planes with different formats from the users-space.

For example, if the user chooses:
- DRM_FORMAT_ARGB16161616 to the primary plane
- DRM_FORMAT_ARGB8888 to the cursor
- DRM_FORMAT_YUV42 to the overlay

What should be the output format that will be used to calculate the crc? DRM_FORMAT_ARGB16161616?

My idea was to convert all the planes to the primary, but I'm not sure if it is the right approach.

Best regards,
---
Igor M. A. Torrente

#1 lore raw

Ideally the final composition format would have enough precision for all of the planes. I think it'd make sense to use ARGB16161616 if the primary plane uses ARGB8888 and an overlay plane uses ARGB16161616.

To simplify the code, maybe it's fine to always use ARGB16161616 for the output, and add getters which fetch an ARGB16161616 row for each supported plane format.

#2 lore raw
Quoted 8 lines · Simon Ser

Ideally the final composition format would have enough precision for all of the planes. I think it'd make sense to use ARGB16161616 if the primary plane uses ARGB8888 and an overlay plane uses ARGB16161616.

To simplify the code, maybe it's fine to always use ARGB16161616 for the output, and add getters which fetch an ARGB16161616 row for each supported plane format.

This makes sense to me. I will try to implement this way.

Thanks!