aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarton Balint <cus@passwd.hu>2019-02-02 11:32:50 +0100
committerMarton Balint <cus@passwd.hu>2019-02-07 23:38:53 +0100
commit28dd73a4437a61340bde29c8fac489ea371ba9cb (patch)
tree9af68ab1dcaf6b9ceb5f73139b7974d0de0e4b74
parent2b8458fcc5d503d0587f14d1fe9107878691cbae (diff)
downloadffmpeg-28dd73a4437a61340bde29c8fac489ea371ba9cb.tar.gz
ffplay: use different decoder names for each media type
Signed-off-by: Marton Balint <cus@passwd.hu>
-rw-r--r--fftools/ffplay.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fftools/ffplay.c b/fftools/ffplay.c
index 6a195e5542..97009f322d 100644
--- a/fftools/ffplay.c
+++ b/fftools/ffplay.c
@@ -2103,10 +2103,10 @@ static int audio_thread(void *arg)
return ret;
}
-static int decoder_start(Decoder *d, int (*fn)(void *), void *arg)
+static int decoder_start(Decoder *d, int (*fn)(void *), const char *thread_name, void* arg)
{
packet_queue_start(d->queue);
- d->decoder_tid = SDL_CreateThread(fn, "decoder", arg);
+ d->decoder_tid = SDL_CreateThread(fn, thread_name, arg);
if (!d->decoder_tid) {
av_log(NULL, AV_LOG_ERROR, "SDL_CreateThread(): %s\n", SDL_GetError());
return AVERROR(ENOMEM);
@@ -2676,7 +2676,7 @@ static int stream_component_open(VideoState *is, int stream_index)
is->auddec.start_pts = is->audio_st->start_time;
is->auddec.start_pts_tb = is->audio_st->time_base;
}
- if ((ret = decoder_start(&is->auddec, audio_thread, is)) < 0)
+ if ((ret = decoder_start(&is->auddec, audio_thread, "audio_decoder", is)) < 0)
goto out;
SDL_PauseAudioDevice(audio_dev, 0);
break;
@@ -2685,7 +2685,7 @@ static int stream_component_open(VideoState *is, int stream_index)
is->video_st = ic->streams[stream_index];
decoder_init(&is->viddec, avctx, &is->videoq, is->continue_read_thread);
- if ((ret = decoder_start(&is->viddec, video_thread, is)) < 0)
+ if ((ret = decoder_start(&is->viddec, video_thread, "video_decoder", is)) < 0)
goto out;
is->queue_attachments_req = 1;
break;
@@ -2694,7 +2694,7 @@ static int stream_component_open(VideoState *is, int stream_index)
is->subtitle_st = ic->streams[stream_index];
decoder_init(&is->subdec, avctx, &is->subtitleq, is->continue_read_thread);
- if ((ret = decoder_start(&is->subdec, subtitle_thread, is)) < 0)
+ if ((ret = decoder_start(&is->subdec, subtitle_thread, "subtitle_decoder", is)) < 0)
goto out;
break;
default: