From 96381b0d887ca05ee727c4c644dbd84c200817f7 Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Sun, 3 Mar 2019 16:55:53 +1100 Subject: [PATCH] tools/hello: load shaders using the image path as a base --- tools/hello.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/hello.cpp b/tools/hello.cpp index 76fbdd5..0681d33 100644 --- a/tools/hello.cpp +++ b/tools/hello.cpp @@ -25,6 +25,7 @@ #include #include #include +#include #include #include @@ -501,8 +502,9 @@ main (void) //------------------------------------------------------------------------- - auto vert_module = cruft::vk::make_owned (ldevice, "./hello.vert.spv"); - auto frag_module = cruft::vk::make_owned (ldevice, "./hello.frag.spv"); + auto const cwd = cruft::image_path ().parent_path (); + auto vert_module = cruft::vk::make_owned (ldevice, cwd / "hello.vert.spv"); + auto frag_module = cruft::vk::make_owned (ldevice, cwd / "hello.frag.spv"); //-------------------------------------------------------------------------