make Pixmap::new() implementation actually use the provided arguments
@@ -41,9 +41,9 @@ impl Handle<SkPixmap> {
assert!(pixels.len() >= height * row_bytes);
let pm = Pixmap::from_native(SkPixmap {
- fPixels: ptr::null(),
- fRowBytes: 0,
- fInfo: ImageInfo::new_unknown(None).native().clone(),
+ fPixels: pixels.as_ptr() as _,
+ fRowBytes: row_bytes,
+ fInfo: info.native().clone(),
});
pm.borrows(pixels)
}
