[librsvg: 15/30] benches: update per api changes
- From: Marge Bot <marge-bot src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [librsvg: 15/30] benches: update per api changes
- Date: Wed, 23 Jun 2021 23:05:39 +0000 (UTC)
commit 4cd266552a516811e7c2532b7fa874599655c962
Author: Bilal Elmoussaoui <bil elmoussaoui gmail com>
Date: Thu Jun 17 14:07:21 2021 +0200
benches: update per api changes
Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/516>
benches/pixel_iterators.rs | 2 +-
benches/surface_from_pixbuf.rs | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/benches/pixel_iterators.rs b/benches/pixel_iterators.rs
index 43bdf4de..031e3a75 100644
--- a/benches/pixel_iterators.rs
+++ b/benches/pixel_iterators.rs
@@ -21,7 +21,7 @@ fn bench_pixel_iterators(c: &mut Criterion) {
let mut surface =
ExclusiveImageSurface::new(SURFACE_SIDE, SURFACE_SIDE, SurfaceType::SRgb).unwrap();
let stride = surface.stride() as i32;
- let data = surface.get_data();
+ let data = surface.data();
let bounds = black_box(BOUNDS);
diff --git a/benches/surface_from_pixbuf.rs b/benches/surface_from_pixbuf.rs
index 72bdc2a1..906e93af 100644
--- a/benches/surface_from_pixbuf.rs
+++ b/benches/surface_from_pixbuf.rs
@@ -14,8 +14,8 @@ fn bench_surface_from_pixbuf(c: &mut Criterion) {
let pixbuf = Pixbuf::new(Colorspace::Rgb, *alpha, 8, 256, 256).unwrap();
// Fill the surface with interesting data
- for y in 0..pixbuf.get_width() {
- for x in 0..pixbuf.get_height() {
+ for y in 0..pixbuf.width() {
+ for x in 0..pixbuf.height() {
pixbuf.put_pixel(
x as u32,
y as u32,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]