mirror of
https://github.com/starovoid/rxing.git
synced 2026-07-26 12:22:34 +00:00
still working on tests
This commit is contained in:
@@ -417,3 +417,15 @@ impl Into<Vec<u8>> for BitArray {
|
||||
// arr
|
||||
}
|
||||
}
|
||||
|
||||
impl Into<Vec<bool>> for BitArray {
|
||||
fn into(self) -> Vec<bool> {
|
||||
let mut array = vec![false; self.size];
|
||||
|
||||
for pixel in 0..self.size {
|
||||
array[pixel] = bool::from(self.get(pixel));
|
||||
}
|
||||
|
||||
array
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user