mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2026-03-13 09:00:40 +08:00
hwcontext_vulkan: fix planar 10 and 12-bit RGB formats using the new MSB formats
This commit is contained in:
@@ -242,8 +242,8 @@ static int run_rct_search(AVCodecContext *avctx, FFVkExecContext *exec,
|
||||
.micro_version = f->micro_version,
|
||||
};
|
||||
|
||||
if (avctx->sw_pix_fmt == AV_PIX_FMT_GBRP10 ||
|
||||
avctx->sw_pix_fmt == AV_PIX_FMT_GBRP12 ||
|
||||
if (avctx->sw_pix_fmt == AV_PIX_FMT_GBRP10MSB ||
|
||||
avctx->sw_pix_fmt == AV_PIX_FMT_GBRP12MSB ||
|
||||
avctx->sw_pix_fmt == AV_PIX_FMT_GBRP14)
|
||||
memcpy(pd.fmt_lut, (int [4]) { 2, 1, 0, 3 }, 4*sizeof(int));
|
||||
else
|
||||
@@ -503,8 +503,8 @@ static int vulkan_encode_ffv1_submit_frame(AVCodecContext *avctx,
|
||||
};
|
||||
|
||||
/* For some reason the C FFv1 encoder/decoder treats these differently */
|
||||
if (avctx->sw_pix_fmt == AV_PIX_FMT_GBRP10 ||
|
||||
avctx->sw_pix_fmt == AV_PIX_FMT_GBRP12 ||
|
||||
if (avctx->sw_pix_fmt == AV_PIX_FMT_GBRP10MSB ||
|
||||
avctx->sw_pix_fmt == AV_PIX_FMT_GBRP12MSB ||
|
||||
avctx->sw_pix_fmt == AV_PIX_FMT_GBRP14)
|
||||
memcpy(pd.fmt_lut, (int [4]) { 2, 1, 0, 3 }, 4*sizeof(int));
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user