diff --git a/channels/tsmf/client/ffmpeg/tsmf_ffmpeg.c b/channels/tsmf/client/ffmpeg/tsmf_ffmpeg.c index c817580b8..4136ab7ba 100644 --- a/channels/tsmf/client/ffmpeg/tsmf_ffmpeg.c +++ b/channels/tsmf/client/ffmpeg/tsmf_ffmpeg.c @@ -442,7 +442,10 @@ static BOOL tsmf_ffmpeg_decode_video(ITSMFDecoder* decoder, const BYTE* data, UI mdecoder->codec_context->pix_fmt, mdecoder->codec_context->width, mdecoder->codec_context->height, 1); - const uint8_t* const* ptr = (const uint8_t* const*)mdecoder->frame->data; + const uint8_t* ptr[AV_NUM_DATA_POINTERS] = { 0 }; + for (size_t x = 0; x < AV_NUM_DATA_POINTERS; x++) + ptr[x] = mdecoder->frame->data[x]; + av_image_copy(frame->data, frame->linesize, ptr, mdecoder->frame->linesize, mdecoder->codec_context->pix_fmt, mdecoder->codec_context->width, mdecoder->codec_context->height);