Skip to content

Commit

Permalink
Fix audio-only playback
Browse files Browse the repository at this point in the history
  • Loading branch information
jyavenard committed Dec 20, 2010
1 parent 1ef81e1 commit 3cf32e8
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions mythtv/libs/libmythtv/avformatdecoder.cpp
Expand Up @@ -3928,10 +3928,6 @@ bool AvFormatDecoder::ProcessAudioPacket(AVStream *curstream, AVPacket *pkt,
int audSubIdx = selectedTrack[kTrackTypeAudio].av_substream_index;
avcodeclock->unlock();

uint ofill = 0, ototal = 0, othresh = 0, total_decoded_audio = 0;
allowedquit = (!(decodetype & kDecodeAudio)) &&
m_audio->IsBufferAlmostFull();

if (pkt->dts != (int64_t)AV_NOPTS_VALUE)
pts = (long long)(av_q2d(curstream->time_base) * pkt->dts * 1000);

Expand Down Expand Up @@ -4092,9 +4088,9 @@ bool AvFormatDecoder::ProcessAudioPacket(AVStream *curstream, AVPacket *pkt,

m_audio->AddAudioData((char *)audioSamples, data_size, temppts);

total_decoded_audio += data_size;

allowedquit |= ringBuffer->InDVDMenuOrStillFrame();
allowedquit |=
ringBuffer->InDVDMenuOrStillFrame() ||
m_audio->IsBufferAlmostFull();

tmp_pkt.data += ret;
tmp_pkt.size -= ret;
Expand Down

0 comments on commit 3cf32e8

Please sign in to comment.