(b: &mut Bencher)
| 7 | |
| 8 | #[bench] |
| 9 | fn histogram(b: &mut Bencher) { |
| 10 | let img = lodepng::decode32_file("/Users/kornel/Desktop/canvas.png").unwrap(); |
| 11 | let liq = Attributes::new(); |
| 12 | b.iter(move || { |
| 13 | let mut img = liq.new_image(&*img.buffer, img.width, img.height, 0.).unwrap(); |
| 14 | let mut hist = Histogram::new(&liq); |
| 15 | hist.add_image(&liq, &mut img).unwrap(); |
| 16 | }); |
| 17 | } |
| 18 | |
| 19 | #[bench] |
| 20 | fn remap_ord(b: &mut Bencher) { |