Skip to content

Commit

Permalink
fixed examples/tuto-14.rs image path (glium#1971)
Browse files Browse the repository at this point in the history
  • Loading branch information
alberto-nanni authored Nov 30, 2021
1 parent a2f0b4c commit e5dc1e7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/tutorial-14.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ fn main() {
]).unwrap();


let image = image::load(Cursor::new(&include_bytes!("../book/tuto-14-diffuse.jpg")),
let image = image::load(Cursor::new(&include_bytes!("../book/resources/tuto-14-diffuse.jpg")),
image::ImageFormat::Jpeg).unwrap().to_rgba8();
let image_dimensions = image.dimensions();
let image = glium::texture::RawImage2d::from_raw_rgba_reversed(&image.into_raw(), image_dimensions);
let diffuse_texture = glium::texture::SrgbTexture2d::new(&display, image).unwrap();

let image = image::load(Cursor::new(&include_bytes!("../book/tuto-14-normal.png")),
let image = image::load(Cursor::new(&include_bytes!("../book/resources/tuto-14-normal.png")),
image::ImageFormat::Png).unwrap().to_rgba8();
let image_dimensions = image.dimensions();
let image = glium::texture::RawImage2d::from_raw_rgba_reversed(&image.into_raw(), image_dimensions);
Expand Down

0 comments on commit e5dc1e7

Please sign in to comment.