Skip to content

va: decoder: Do not only consider chroma when get preferred format.

He Junyan requested to merge He_Junyan/gstreamer:decoder_default_format into main

The current way of preferred format selection is not complete. It only choose the formats which has the same chroma type with the decoder's rt_format. The rt_format tells the decoder which chroma type the stream is, but it is not decisive for the output surface format. For example, main-10 profile of HEVC can also contain and decode 8 bits stream. But that profile/entrypoint pair just support P010_10LE as the output format. So we fail all these cases because format selection is UNKNOWN.

The better way should be that we consider the chroma first, and choose a default one in our decoder's src caps if we can not find one.

Merge request reports