[FFmpeg-soc] [soc]: r3142 - mlp/mlpenc.c
ramiro
subversion at mplayerhq.hu
Sun Aug 10 16:26:21 CEST 2008
Author: ramiro
Date: Sun Aug 10 16:26:21 2008
New Revision: 3142
Log:
Only check if next offset is out of upper or lower bounds instead of both.
Modified:
mlp/mlpenc.c
Modified: mlp/mlpenc.c
==============================================================================
--- mlp/mlpenc.c (original)
+++ mlp/mlpenc.c Sun Aug 10 16:26:21 2008
@@ -803,8 +803,7 @@ static void codebook_bits(MLPEncodeConte
int offset;
int next;
- for (offset = average; offset >= offset_min &&
- offset <= offset_max;) {
+ for (offset = average; ;) {
BestOffset temp_bo;
codebook_bits_offset(ctx, substr, channel, codebook,
@@ -823,8 +822,12 @@ static void codebook_bits(MLPEncodeConte
if (direction) {
offset += next;
+ if (offset > offset_max)
+ break;
} else {
offset -= next;
+ if (offset < offset_min)
+ break;
}
}
}
More information about the FFmpeg-soc
mailing list