Skip to content
This repository has been archived by the owner on Jun 11, 2020. It is now read-only.

Commit

Permalink
Updated tutorial07.c, fixed issue #4
Browse files Browse the repository at this point in the history
  • Loading branch information
mpenkov committed Oct 29, 2012
1 parent 1c430e4 commit 796adc0
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions tutorial07.c
Original file line number Diff line number Diff line change
Expand Up @@ -310,12 +310,6 @@ int audio_decode_frame(VideoState *is, double *pts_ptr) {
is->audio_pkt_size = 0;
break;
}
is->audio_pkt_data += len1;
is->audio_pkt_size -= len1;
if(data_size <= 0) {
/* No data yet, get more frames */
continue;
}
if (got_frame)
{
data_size =
Expand All @@ -329,6 +323,12 @@ int audio_decode_frame(VideoState *is, double *pts_ptr) {
);
memcpy(is->audio_buf, is->audio_frame.data[0], data_size);
}
is->audio_pkt_data += len1;
is->audio_pkt_size -= len1;
if(data_size <= 0) {
/* No data yet, get more frames */
continue;
}
pts = is->audio_clock;
*pts_ptr = pts;
n = 2 * is->audio_st->codec->channels;
Expand Down

0 comments on commit 796adc0

Please sign in to comment.