[FFmpeg-devel] [PATCH] Fix multithreaded MPEG-4 decoding.
Michael Niedermayer
michaelni at gmx.at
Thu Apr 18 20:57:17 CEST 2013
On Thu, Apr 18, 2013 at 07:13:56PM +0200, Reimar Döffinger wrote:
> Regression since c10d498bfd246a40cc7830838b74e18a79418839.
> Unfortunately ff_thread_get_format can only be called from
> a separate decode thread, running it during init will fail.
> Fixes for that are welcome, for now just revert back to
> calling avctx->get_format directly, which is correct
> but having to decide on a case-by-case basis which approach
> to use is a bit messy.
not using get_format() for anything but getting the format would
solve this mess, i mean no sideeffects like initializing some hardware
>
> Signed-off-by: Reimar Döffinger <Reimar.Doeffinger at gmx.de>
> ---
> libavcodec/h263dec.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/libavcodec/h263dec.c b/libavcodec/h263dec.c
> index cc87bc7..405d3c6 100644
> --- a/libavcodec/h263dec.c
> +++ b/libavcodec/h263dec.c
> @@ -64,7 +64,7 @@ av_cold int ff_h263_decode_init(AVCodecContext *avctx)
> if (avctx->codec->id == AV_CODEC_ID_MSS2)
> avctx->pix_fmt = AV_PIX_FMT_YUV420P;
> else
> - avctx->pix_fmt = ff_thread_get_format(avctx, avctx->codec->pix_fmts);
> + avctx->pix_fmt = avctx->get_format(avctx, avctx->codec->pix_fmts);
> s->unrestricted_mv= 1;
LGTM
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I am the wisest man alive, for I know one thing, and that is that I know
nothing. -- Socrates
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130418/367b32d0/attachment.asc>
More information about the ffmpeg-devel
mailing list