[vlc-commits] [Git][videolan/vlc][master] avcodec: reset the output mask with VA after we reset the chroma
Steve Lhomme (@robUx4)
gitlab at videolan.org
Sun Sep 3 12:17:51 UTC 2023
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
10f2ca94 by Steve Lhomme at 2023-09-03T12:04:12+00:00
avcodec: reset the output mask with VA after we reset the chroma
If the chroma really needs a mask, it should set it. But when we reset the
chroma we should reset the mask as well.
- - - - -
2 changed files:
- modules/codec/avcodec/d3d11va.c
- modules/codec/avcodec/video.c
Changes:
=====================================
modules/codec/avcodec/d3d11va.c
=====================================
@@ -283,8 +283,6 @@ static int Open(vlc_va_t *va, AVCodecContext *ctx, enum AVPixelFormat hwfmt, con
}
final_fmt.i_chroma = sys->render_fmt->fourcc;
- final_fmt.i_rmask = final_fmt.i_gmask = final_fmt.i_bmask = 0;
- video_format_FixRgb(&final_fmt);
err = va_pool_SetupDecoder(va, sys->va_pool, ctx, &final_fmt, sys->hw.surface_count);
if (err != VLC_SUCCESS)
goto error;
=====================================
modules/codec/avcodec/video.c
=====================================
@@ -651,6 +651,9 @@ static int ffmpeg_OpenVa(decoder_t *p_dec, AVCodecContext *p_context,
vlc_mutex_unlock(open_lock);
p_dec->fmt_out.video.i_chroma = 0; // make sure the va sets its output chroma
+ p_dec->fmt_out.video.i_rmask = 0;
+ p_dec->fmt_out.video.i_gmask = 0;
+ p_dec->fmt_out.video.i_bmask = 0;
vlc_video_context *vctx_out;
vlc_va_t *va = vlc_va_New(VLC_OBJECT(p_dec), p_context, hwfmt, src_desc,
p_dec->fmt_in, init_device,
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/10f2ca94d872477440ff54978d493aff904a41c5
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/10f2ca94d872477440ff54978d493aff904a41c5
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list