[FFmpeg-cvslog] alac: conditionally set sign_modifier to 1
Justin Ruggles
git at videolan.org
Thu Jul 19 23:35:50 CEST 2012
ffmpeg | branch: master | Justin Ruggles <justin.ruggles at gmail.com> | Mon Jul 9 10:57:42 2012 -0400| [5177413d2043109f3e689e5fbfa79411c0c8e09d] | committer: Justin Ruggles
alac: conditionally set sign_modifier to 1
It is already unconditionally set to 0 prior to this, so we can modify it
only when needed.
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=5177413d2043109f3e689e5fbfa79411c0c8e09d
---
libavcodec/alac.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/libavcodec/alac.c b/libavcodec/alac.c
index 2aab84c..0aeb410 100644
--- a/libavcodec/alac.c
+++ b/libavcodec/alac.c
@@ -133,8 +133,6 @@ static void bastardized_rice_decompress(ALACContext *alac,
int k;
unsigned int block_size;
- sign_modifier = 1;
-
k = 7 - av_log2(history) + ((history + 16) >> 6 /* / 64 */);
k = FFMIN(k, alac->rice_limit);
@@ -149,8 +147,8 @@ static void bastardized_rice_decompress(ALACContext *alac,
output_count += block_size;
}
- if (block_size > 0xffff)
- sign_modifier = 0;
+ if (block_size <= 0xffff)
+ sign_modifier = 1;
history = 0;
}
More information about the ffmpeg-cvslog
mailing list