mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 16:08:04 +02:00
radeonsi/vcn: fix regression in yuv422 jpeg decode
- yuv422 decode was blocked in12acee17fa, enable it back. - nv12 yuv422 and grayscale decode is supported on all versions. - JPEG2 and higher versions supports 444p decode. - add l8_unorm to supported formats, can be used for grayscale. Fixes:12acee17fa(frontends/va: reallocate surface for yuv400/yuv444 picture) v2: indent the switch case correctly (Thong Thai) Signed-off-by: Sathishkumar S <sathishkumar.sundararaju@amd.com> Reviewed-by: Thong Thai <thong.thai@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20165>
This commit is contained in:
parent
b4f940913d
commit
7ad4a5079e
1 changed files with 14 additions and 7 deletions
|
|
@ -854,13 +854,20 @@ static bool si_vid_is_format_supported(struct pipe_screen *screen, enum pipe_for
|
|||
|
||||
/* JPEG supports YUV400 and YUV444 */
|
||||
if (profile == PIPE_VIDEO_PROFILE_JPEG_BASELINE) {
|
||||
if (sscreen->info.family >= CHIP_NAVI21 || sscreen->info.family == CHIP_MI100 ||
|
||||
sscreen->info.family == CHIP_MI200)
|
||||
return (format == PIPE_FORMAT_NV12 || format == PIPE_FORMAT_Y8_400_UNORM ||
|
||||
format == PIPE_FORMAT_Y8_U8_V8_444_UNORM || format == PIPE_FORMAT_YUYV);
|
||||
else
|
||||
return (format == PIPE_FORMAT_NV12);
|
||||
|
||||
switch (format) {
|
||||
case PIPE_FORMAT_NV12:
|
||||
case PIPE_FORMAT_YUYV:
|
||||
case PIPE_FORMAT_L8_UNORM:
|
||||
case PIPE_FORMAT_Y8_400_UNORM:
|
||||
return true;
|
||||
case PIPE_FORMAT_Y8_U8_V8_444_UNORM:
|
||||
if (sscreen->info.family >= CHIP_RENOIR)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/* we can only handle this one with UVD */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue