mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-libstb-hal.git
synced 2025-08-27 07:22:44 +02:00
generic-pc: improve decoder info messages
Origin commit data
------------------
Branch: master
Commit: 94830cf33f
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2013-06-01 (Sat, 01 Jun 2013)
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -329,6 +329,7 @@ void cAudio::run()
|
||||
int obuf_sz_max = 0;
|
||||
int o_ch, o_sr; /* output channels and sample rate */
|
||||
uint64_t o_layout; /* output channels layout */
|
||||
char tmp[64] = "unknown";
|
||||
|
||||
curr_pts = 0;
|
||||
av_init_packet(&avpkt);
|
||||
@@ -362,7 +363,7 @@ void cAudio::run()
|
||||
c = avfc->streams[0]->codec;
|
||||
codec = avcodec_find_decoder(c->codec_id);
|
||||
if (!codec) {
|
||||
lt_info("%s: Codec not found\n", __func__);
|
||||
lt_info("%s: Codec for %s not found\n", __func__, avcodec_get_name(c->codec_id));
|
||||
goto out;
|
||||
}
|
||||
if (avcodec_open2(c, codec, NULL) < 0) {
|
||||
@@ -402,8 +403,9 @@ void cAudio::run()
|
||||
fprintf(stderr, " %s", ai->options[i]);
|
||||
fprintf(stderr, "\n");
|
||||
#endif
|
||||
lt_info("codec params: sample_fmt %d sample_rate %d channels %d\n",
|
||||
c->sample_fmt, c->sample_rate, c->channels);
|
||||
av_get_sample_fmt_string(tmp, sizeof(tmp), c->sample_fmt);
|
||||
lt_info("decoding %s, sample_fmt %d (%s) sample_rate %d channels %d\n",
|
||||
avcodec_get_name(c->codec_id), c->sample_fmt, tmp, c->sample_rate, c->channels);
|
||||
swr = swr_alloc_set_opts(swr,
|
||||
o_layout, AV_SAMPLE_FMT_S16, o_sr, /* output */
|
||||
c->channel_layout, c->sample_fmt, c->sample_rate, /* input */
|
||||
|
@@ -445,7 +445,7 @@ void cVideo::run(void)
|
||||
c = avfc->streams[0]->codec;
|
||||
codec = avcodec_find_decoder(c->codec_id);
|
||||
if (!codec) {
|
||||
lt_info("%s: Codec not found\n", __func__);
|
||||
lt_info("%s: Codec for %s not found\n", __func__, avcodec_get_name(c->codec_id));
|
||||
goto out;
|
||||
}
|
||||
if (avcodec_open2(c, codec, NULL) < 0) {
|
||||
@@ -458,6 +458,7 @@ void cVideo::run(void)
|
||||
lt_info("%s: Could not allocate video frame\n", __func__);
|
||||
goto out2;
|
||||
}
|
||||
lt_info("decoding %s\n", avcodec_get_name(c->codec_id));
|
||||
while (thread_running) {
|
||||
if (av_read_frame(avfc, &avpkt) < 0) {
|
||||
if (warn_r - time(NULL) > 4) {
|
||||
|
Reference in New Issue
Block a user