Changed to use u32 for chunk_index

This commit is contained in:
Alan Race committed 2022-07-11 08:56:35 +02:00
1 parent e1f4161e0b
commit 5cadbffebf
5 files changed
+74 -62

No files matched your search

+1 -1
View File
@@ -275,7 +275,7 @@ fn test_tiled_incremental() {
assert_eq!(tiles as usize, sums.len());
for tile in 0..tiles {
match decoder.read_chunk_at(tile as usize).unwrap() {
match decoder.read_chunk(tile).unwrap() {
(DecodingResult::U8(res), _) => {
let sum: u64 = res.into_iter().map(<u64>::from).sum();
assert_eq!(sum, sums[tile as usize]);
+1 -1
View File
@@ -512,7 +512,7 @@ fn test_rows_per_strip() {
for i in 0..50 {
let img2 = [i; 2 * 100];
match decoder.read_chunk_at(i as usize).unwrap() {
match decoder.read_chunk(i as u32).unwrap() {
(DecodingResult::U8(data), _) => assert_eq!(&img2[..], &data[..]),
other => panic!("Incorrect strip type {:?}", other),
}