diff options
author | Alexander Strange <astrange@ithinksw.com> | 2010-12-15 03:22:47 +0300 |
---|---|---|
committer | Alexander Strange <astrange@ithinksw.com> | 2010-12-15 03:22:47 +0300 |
commit | 0f01602362f20bbc819dd07926cd2bb0a89a6c4d (patch) | |
tree | 5909f47df19a2684a0cf06f69e6164c33a0f8d88 /libavcodec/h264.c | |
parent | 1aa58c6405dad2663257260b993791f43c0da76b (diff) |
SVQ3: Allow decoding if thread_count is > 1
svq3 still doesn't support multithreading, but it's simpler for clients if
they can enable threading for all codecs by default.
Originally committed as revision 26015 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r-- | libavcodec/h264.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 9198d7cb50..318c1c8355 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -979,7 +979,7 @@ int ff_h264_frame_start(H264Context *h){ /* can't be in alloc_tables because linesize isn't known there. * FIXME: redo bipred weight to not require extra buffer? */ for(i = 0; i < s->avctx->thread_count; i++) - if(!h->thread_context[i]->s.obmc_scratchpad) + if(h->thread_context[i] && !h->thread_context[i]->s.obmc_scratchpad) h->thread_context[i]->s.obmc_scratchpad = av_malloc(16*2*s->linesize + 8*2*s->uvlinesize); /* some macroblocks can be accessed before they're available in case of lost slices, mbaff or threading*/ |