aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>2020-12-10 05:42:35 +0100
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-04-27 00:42:20 +0200
commit0d30c04e5d1414b402a3ea45e586b955a286333e (patch)
treeca72d71a4e408b89a343a3d724a786193d633c58 /libavcodec
parent26798932ae13f3505dc50be30f17796c4c8c9e67 (diff)
downloadffmpeg-0d30c04e5d1414b402a3ea45e586b955a286333e.tar.gz
avcodec/msmpeg4: Reindentation
Forgotten in/after f5957f3fe2b8dfda13a9750acc3e3a03cd5d39c9. Reviewed-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/msmpeg4.c90
1 files changed, 44 insertions, 46 deletions
diff --git a/libavcodec/msmpeg4.c b/libavcodec/msmpeg4.c
index ea1083c1a0..6673b45231 100644
--- a/libavcodec/msmpeg4.c
+++ b/libavcodec/msmpeg4.c
@@ -53,56 +53,54 @@
* except that it is inverted. */
static av_cold void init_h263_dc_for_msmpeg4(void)
{
- int level, uni_code, uni_len;
-
- for(level=-256; level<256; level++){
- int size, v, l;
- /* find number of bits */
- size = 0;
- v = abs(level);
- while (v) {
- v >>= 1;
- size++;
- }
+ for (int level = -256; level < 256; level++) {
+ int uni_code, uni_len;
+ int size, v, l;
+ /* find number of bits */
+ size = 0;
+ v = abs(level);
+ while (v) {
+ v >>= 1;
+ size++;
+ }
- if (level < 0)
- l= (-level) ^ ((1 << size) - 1);
- else
- l= level;
-
- /* luminance H.263 */
- uni_code= ff_mpeg4_DCtab_lum[size][0];
- uni_len = ff_mpeg4_DCtab_lum[size][1];
- uni_code ^= (1<<uni_len)-1; //M$ does not like compatibility
-
- if (size > 0) {
- uni_code<<=size; uni_code|=l;
- uni_len+=size;
- if (size > 8){
- uni_code<<=1; uni_code|=1;
- uni_len++;
- }
+ if (level < 0)
+ l = (-level) ^ ((1 << size) - 1);
+ else
+ l = level;
+
+ /* luminance H.263 */
+ uni_code = ff_mpeg4_DCtab_lum[size][0];
+ uni_len = ff_mpeg4_DCtab_lum[size][1];
+ uni_code ^= (1 << uni_len) - 1; //M$ does not like compatibility
+
+ if (size > 0) {
+ uni_code <<= size; uni_code |= l;
+ uni_len += size;
+ if (size > 8) {
+ uni_code <<= 1; uni_code |= 1;
+ uni_len++;
}
- ff_v2_dc_lum_table[level + 256][0] = uni_code;
- ff_v2_dc_lum_table[level + 256][1] = uni_len;
-
- /* chrominance H.263 */
- uni_code= ff_mpeg4_DCtab_chrom[size][0];
- uni_len = ff_mpeg4_DCtab_chrom[size][1];
- uni_code ^= (1<<uni_len)-1; //M$ does not like compatibility
-
- if (size > 0) {
- uni_code<<=size; uni_code|=l;
- uni_len+=size;
- if (size > 8){
- uni_code<<=1; uni_code|=1;
- uni_len++;
- }
+ }
+ ff_v2_dc_lum_table[level + 256][0] = uni_code;
+ ff_v2_dc_lum_table[level + 256][1] = uni_len;
+
+ /* chrominance H.263 */
+ uni_code = ff_mpeg4_DCtab_chrom[size][0];
+ uni_len = ff_mpeg4_DCtab_chrom[size][1];
+ uni_code ^= (1 << uni_len) - 1; //M$ does not like compatibility
+
+ if (size > 0) {
+ uni_code <<= size; uni_code |= l;
+ uni_len +=size;
+ if (size > 8) {
+ uni_code <<= 1; uni_code |= 1;
+ uni_len++;
}
- ff_v2_dc_chroma_table[level + 256][0] = uni_code;
- ff_v2_dc_chroma_table[level + 256][1] = uni_len;
-
}
+ ff_v2_dc_chroma_table[level + 256][0] = uni_code;
+ ff_v2_dc_chroma_table[level + 256][1] = uni_len;
+ }
}
av_cold void ff_msmpeg4_common_init(MpegEncContext *s)