Mercurial > libavformat.hg
comparison vocdec.c @ 1884:1792b6c5387b libavformat
simplification
author | alex |
---|---|
date | Wed, 07 Mar 2007 00:29:51 +0000 |
parents | a6cf9ee93fbb |
children | 1a3c9056982a |
comparison
equal
deleted
inserted
replaced
1883:a6cf9ee93fbb | 1884:1792b6c5387b |
---|---|
20 */ | 20 */ |
21 | 21 |
22 #include "voc.h" | 22 #include "voc.h" |
23 | 23 |
24 | 24 |
25 static const int voc_max_pkt_size = 2048; | |
26 | 25 |
27 | 26 |
28 static int voc_probe(AVProbeData *p) | 27 static int voc_probe(AVProbeData *p) |
29 { | 28 { |
30 int version, check; | 29 int version, check; |
126 } | 125 } |
127 | 126 |
128 dec->bit_rate = dec->sample_rate * dec->bits_per_sample; | 127 dec->bit_rate = dec->sample_rate * dec->bits_per_sample; |
129 | 128 |
130 if (max_size <= 0) | 129 if (max_size <= 0) |
131 max_size = voc_max_pkt_size; | 130 max_size = 2048; |
132 size = FFMIN(voc->remaining_size, max_size); | 131 size = FFMIN(voc->remaining_size, max_size); |
133 voc->remaining_size -= size; | 132 voc->remaining_size -= size; |
134 return av_get_packet(pb, pkt, size); | 133 return av_get_packet(pb, pkt, size); |
135 } | 134 } |
136 | 135 |