Browse Source

threads: restore has_b_frames in frame_thread_free

Otherwise the delay expressed in has_b_frames increases with every
avcodec_close/avcodec_open.
Fixes fate-ea-dct with more than 1 thread.
tags/n0.9
Janne Grunau 14 years ago
parent
commit
d6174bfe5f
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      libavcodec/pthread.c

+ 1
- 0
libavcodec/pthread.c View File

@@ -681,6 +681,7 @@ static void frame_thread_free(AVCodecContext *avctx, int thread_count)
av_freep(&fctx->threads);
pthread_mutex_destroy(&fctx->buffer_mutex);
av_freep(&avctx->thread_opaque);
avctx->has_b_frames -= avctx->thread_count - 1;
}

static int frame_thread_init(AVCodecContext *avctx)


Loading…
Cancel
Save