OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b22f9d6
)
10l: fix bit count for frame header
author
Justin Ruggles
<justin.ruggles@gmail.com>
Sat, 31 Jul 2010 18:48:48 +0000
(18:48 +0000)
committer
Justin Ruggles
<justin.ruggles@gmail.com>
Sat, 31 Jul 2010 18:48:48 +0000
(18:48 +0000)
Originally committed as revision 24627 to svn://svn.ffmpeg.org/ffmpeg/trunk
libavcodec/flacenc.c
patch
|
blob
|
history
diff --git
a/libavcodec/flacenc.c
b/libavcodec/flacenc.c
index
d9f9251
..
7d1e773
100644
(file)
--- a/
libavcodec/flacenc.c
+++ b/
libavcodec/flacenc.c
@@
-945,7
+945,10
@@
static int count_frame_header(FlacEncodeContext *s)
PUT_UTF8(s->frame_count, tmp, count += 8;)
/* explicit block size */
- count += FFMAX(0, s->frame.bs_code[0] - 5) * 8;
+ if (s->frame.bs_code[0] == 6)
+ count += 8;
+ else if (s->frame.bs_code[0] == 7)
+ count += 16;
/* explicit sample rate */
count += ((s->sr_code[0] == 12) + (s->sr_code[0] > 12)) * 8;