diff options
author | Johns <johns98@gmx.net> | 2011-12-25 11:36:02 +0100 |
---|---|---|
committer | Johns <johns98@gmx.net> | 2011-12-25 11:36:02 +0100 |
commit | 83413c1adfdd895ffe65087c8270576b3ba4900e (patch) | |
tree | a84ca60f8c2666e4a5c7506ca2f012dc788589cb /codec.c | |
parent | 63d18ea4889d530a92b7569bb773ccc171b3ffbd (diff) | |
download | vdr-plugin-softhddevice-83413c1adfdd895ffe65087c8270576b3ba4900e.tar.gz vdr-plugin-softhddevice-83413c1adfdd895ffe65087c8270576b3ba4900e.tar.bz2 |
Use only one thread for hw decoding.
Diffstat (limited to 'codec.c')
-rw-r--r-- | codec.c | 8 |
1 files changed, 2 insertions, 6 deletions
@@ -337,6 +337,8 @@ void CodecVideoOpen(VideoDecoder * decoder, const char *name, int codec_id) if (!(decoder->VideoCtx = avcodec_alloc_context3(video_codec))) { Fatal(_("codec: can't allocate video codec context\n")); } + // FIXME: for software decoder use all cpus, otherwise 1 + decoder->VideoCtx->thread_count = 1; // open codec #if LIBAVCODEC_VERSION_INT <= AV_VERSION_INT(53,5,0) if (avcodec_open(decoder->VideoCtx, video_codec) < 0) { @@ -350,12 +352,6 @@ void CodecVideoOpen(VideoDecoder * decoder, const char *name, int codec_id) decoder->VideoCtx->opaque = decoder; // our structure - /* - // FIXME: the number of cpu's should be configurable - // Today this makes no big sense H264 is broken with current streams. - avcodec_thread_init(decoder->VideoCtx, 2); // support dual-cpu's - */ - Debug(3, "codec: video '%s'\n", decoder->VideoCtx->codec_name); if (codec_id == CODEC_ID_H264) { // 2.53 Ghz CPU is too slow for this codec at 1080i |