remove trailing whitespaces
[nihav.git] / nihav-core / src / dsp / dct.rs
index ae04e8e88e2ff13da4f35ba5bbfb9183b22bf333..e58ccc706d87ae5ab54f08dcde36eb0bad996bb2 100644 (file)
@@ -48,7 +48,7 @@ impl DCT {
             perm_tab.push(0); // size = 1
             perm_tab.push(0); // size = 2
             perm_tab.push(1);
-            for blen in 2..bits+1 {
+            for blen in 2..=bits {
                 let ssize = 1 << blen;
                 for i in 0..ssize { perm_tab.push(swp_idx(i, blen)); }
             }
@@ -66,7 +66,7 @@ impl DCT {
                     tab.push((consts::PI / 8.0).sin()); // size = 1
                     tab.push((consts::PI / 8.0).cos());
                     if bits > 1 {
-                        for blen in 1..bits+1 {
+                        for blen in 1..=bits {
                             let tsize = 1 << blen;
                             let base = consts::PI / ((tsize * 8) as f32);
                             for i in 0..tsize {
@@ -81,7 +81,7 @@ impl DCT {
                 },*/
             _ => { tab = Vec::new(); },
         };
-        
+
         Self { tmp, tab, mode, size, swaps, perms, is_pow2, perm_tab }
     }
     fn can_do_fast(&mut self) -> bool {
@@ -153,7 +153,7 @@ fn reverse_bits(inval: u32) -> u32 {
     let mut val = inval;
     for _ in 0..8 {
         ret = (ret << 4) | (REV_TAB[(val & 0xF) as usize] as u32);
-        val = val >> 4;
+        val >>= 4;
     }
     ret
 }