Skip to content
Snippets Groups Projects
Commit 04d258da authored by Niklas Haas's avatar Niklas Haas
Browse files

colorspace: treat PL_CHROMA_UNKNOWN as _TOP_LEFT

A lot of subsampled content out there is untagged, but should be treated
as _TOP_LEFT content (the de-facto standard chroma subsampling mode).
However, we effectively treat _UNKNOWN as PL_CHROMA_CENTER. To fix this,
make pl_chroma_location_offset explicitly default the chroma location.

Since a lot of users currently just call that function on the chroma
planes always (regardless of subsampling), introduce a new helper
function `pl_image_set_chroma_location` to only set the plane shift for
actually subsampled planes.

Annoying API break, but it is what it is.
parent 75e9fdb7
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment