diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2005-03-30 00:36:30 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2005-03-30 00:36:30 +0000 |
commit | de39cdf542f390900304ba4674f7cd0b4950370b (patch) | |
tree | 5e33c1b1e28c0a35d7a9fa89fb855cf364a5f002 | |
parent | 5b225466ea808bc5e677150b2e2cdbf5a8f88ce6 (diff) | |
download | ffmpeg-de39cdf542f390900304ba4674f7cd0b4950370b.tar.gz |
reverting 1.66 -> 1.67 change
Originally committed as revision 4096 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavformat/mov.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c index ad51701cae..6bba5ba08e 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -1817,10 +1817,11 @@ static int mov_read_packet(AVFormatContext *s, AVPacket *pkt) #ifdef DEBUG fprintf(stderr, "sc[ffid %d]->sample_size = %d\n", sc->ffindex, sc->sample_size); #endif - // sample_size is not always correct for audio. Quicktime ignores this value and - // computes it differently. - if(s->streams[sc->ffindex]->codec.codec_type == CODEC_TYPE_VIDEO) - size = sc->sample_size?sc->sample_size:sc->sample_sizes[sc->current_sample]; + //size = sc->sample_sizes[sc->current_sample]; + // that ain't working... + //size = (sc->sample_size)?sc->sample_size:sc->sample_sizes[sc->current_sample]; + size = (sc->sample_size > 1)?sc->sample_size:sc->sample_sizes[sc->current_sample]; + sc->current_sample++; sc->left_in_chunk--; @@ -1906,8 +1907,7 @@ again: #ifdef MOV_SPLIT_CHUNKS /* split chunks into samples */ - if (s->streams[sc->ffindex]->codec.codec_type == CODEC_TYPE_VIDEO) { - // This does not support split audio, as the sample_size is often not correct + if (sc->sample_size == 0) { idx = sc->sample_to_chunk_index; if ((idx + 1 < sc->sample_to_chunk_sz) && (sc->next_chunk >= sc->sample_to_chunk[idx + 1].first)) @@ -1917,7 +1917,7 @@ again: mov->partial = sc; /* we'll have to get those samples before next chunk */ sc->left_in_chunk = sc->sample_to_chunk[idx].count - 1; - size = sc->sample_size?sc->sample_size:sc->sample_sizes[sc->current_sample]; + size = (sc->sample_size > 1)?sc->sample_size:sc->sample_sizes[sc->current_sample]; } sc->current_sample++; |