Skip to content

Commit

Permalink
rustfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
fintelia committed Aug 13, 2023
1 parent e702705 commit aaca894
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/codecs/webp/encoder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -483,8 +483,8 @@ impl<W: Write> WebPEncoder<W> {
let len0 = lengths[1][pixel[0] as usize];
let len3 = lengths[3][pixel[1] as usize];

let code = codes[1][pixel[0] as usize] as u64 |
(codes[3][pixel[1] as usize] as u64) << len0;
let code = codes[1][pixel[0] as usize] as u64
| (codes[3][pixel[1] as usize] as u64) << len0;

self.write_bits(code, len0 + len3)?;
}
Expand All @@ -495,9 +495,9 @@ impl<W: Write> WebPEncoder<W> {
let len0 = lengths[0][pixel[0] as usize];
let len2 = lengths[2][pixel[2] as usize];

let code = codes[1][pixel[1] as usize] as u64 |
(codes[0][pixel[0] as usize] as u64) << len1 |
(codes[2][pixel[2] as usize] as u64) << (len1 + len0);
let code = codes[1][pixel[1] as usize] as u64
| (codes[0][pixel[0] as usize] as u64) << len1
| (codes[2][pixel[2] as usize] as u64) << (len1 + len0);

self.write_bits(code, len1 + len0 + len2)?;
}
Expand All @@ -509,10 +509,10 @@ impl<W: Write> WebPEncoder<W> {
let len2 = lengths[2][pixel[2] as usize];
let len3 = lengths[3][pixel[3] as usize];

let code = codes[1][pixel[1] as usize] as u64 |
(codes[0][pixel[0] as usize] as u64) << len1 |
(codes[2][pixel[2] as usize] as u64) << (len1 + len0) |
(codes[3][pixel[3] as usize] as u64) << (len1 + len0 + len2);
let code = codes[1][pixel[1] as usize] as u64
| (codes[0][pixel[0] as usize] as u64) << len1
| (codes[2][pixel[2] as usize] as u64) << (len1 + len0)
| (codes[3][pixel[3] as usize] as u64) << (len1 + len0 + len2);

self.write_bits(code, len1 + len0 + len2 + len3)?;
}
Expand Down

0 comments on commit aaca894

Please sign in to comment.