diff --git a/api/sixtyfps-cpp/lib.rs b/api/sixtyfps-cpp/lib.rs index f19422ca6..a03976444 100644 --- a/api/sixtyfps-cpp/lib.rs +++ b/api/sixtyfps-cpp/lib.rs @@ -26,7 +26,7 @@ pub fn use_modules() -> usize { #[no_mangle] pub unsafe extern "C" fn sixtyfps_windowrc_init(out: *mut WindowRcOpaque) { assert_eq!(core::mem::size_of::(), core::mem::size_of::()); - core::ptr::write(out as *mut WindowRc, crate::backend().create_window().into()); + core::ptr::write(out as *mut WindowRc, crate::backend().create_window()); } #[no_mangle] diff --git a/examples/imagefilter/main.rs b/examples/imagefilter/main.rs index 8a1913f9a..e6ec6c618 100644 --- a/examples/imagefilter/main.rs +++ b/examples/imagefilter/main.rs @@ -99,14 +99,13 @@ pub fn main() { image::open(&cat_path).expect("Error loading cat image").into_rgba8() }; - main_window.set_original_image( - sixtyfps::Image::from_rgba8(sixtyfps::SharedPixelBuffer::clone_from_slice( + main_window.set_original_image(sixtyfps::Image::from_rgba8( + sixtyfps::SharedPixelBuffer::clone_from_slice( source_image.as_raw(), source_image.width() as _, source_image.height() as _, - )) - .into(), - ); + ), + )); let filters = Filters(vec![ Filter {