From 9904d3f06e4b9216b6e1738f89789c188b8dd1ab Mon Sep 17 00:00:00 2001 From: Matthew Gordon Date: Fri, 3 Apr 2020 21:23:38 -0400 Subject: [PATCH] Fix test model path in benchmark --- benches/simple_scene.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/benches/simple_scene.rs b/benches/simple_scene.rs index efeab3a..9118860 100644 --- a/benches/simple_scene.rs +++ b/benches/simple_scene.rs @@ -17,6 +17,9 @@ fn simple_scene(bencher: &mut Criterion) { let image_width = 6; let image_height = 6; + let model_file_path = + Path::new(env!("CARGO_MANIFEST_DIR")).join("test_data/stanford_bunny.obj"); + let scene = Scene { camera_location: Point3::new(-2.0, 1.0, -5.0), objects: vec![ @@ -57,7 +60,7 @@ fn simple_scene(bencher: &mut Criterion) { )), Box::new(BoundingVolumeHierarchy::build( &load_obj( - Path::new("/home/matthew/Downloads/bunny.obj"), + &model_file_path, Arc::new(PhongMaterial { colour: ColourRgbF::from_named(NamedColour::Yellow), diffuse_strength: 0.05,