diff --git a/src/plumbing/transcoding.c b/src/plumbing/transcoding.c index 4c024d6..d7ad28a 100644 --- a/src/plumbing/transcoding.c +++ b/src/plumbing/transcoding.c @@ -492,15 +492,19 @@ transcoder_stream_audio(transcoder_t *t, transcoder_stream_t *ts, th_pkt_t *pkt) icodec = as->aud_icodec; ocodec = as->aud_ocodec; + tvhtrace("transcode", "audio in %ld", (long)pkt->pkt_dts); + if (!avcodec_is_open(ictx)) { if (icodec->id == AV_CODEC_ID_AAC || icodec->id == AV_CODEC_ID_VORBIS) { if (pkt->pkt_meta) { + tvhtrace("transcode", "audio meta!!!"); ictx->extradata_size = pktbuf_len(pkt->pkt_meta); ictx->extradata = av_malloc(ictx->extradata_size); memcpy(ictx->extradata, pktbuf_ptr(pkt->pkt_meta), pktbuf_len(pkt->pkt_meta)); } else { /* wait for metadata */ + tvhtrace("transcode", "audio meta wait"); return; } }