incomplete port of detector

This commit is contained in:
Henry Schimke
2023-03-13 12:35:58 -05:00
parent 5d6f4b1d94
commit e49f873bc9
15 changed files with 632 additions and 212 deletions

View File

@@ -401,3 +401,15 @@ impl Default for BitArray {
Self::new()
}
}
impl Into<Vec<u8>> for BitArray {
fn into(self) -> Vec<u8> {
let mut arr = vec![0; self.get_size()];
for x in 0..self.get_size() {
if self.get(x) {
arr[x] = 1;
}
}
arr
}
}