fix live shader reload
This commit is contained in:
@@ -564,7 +564,7 @@ impl App {
|
||||
.ok();
|
||||
|
||||
if watcher.is_some()
|
||||
&& let Ok(paths) = std::fs::read_dir("src/shaders")
|
||||
&& let Ok(paths) = std::fs::read_dir("tape-drive/src/shaders")
|
||||
{
|
||||
for path in paths {
|
||||
if let Ok(path) = path
|
||||
@@ -1740,6 +1740,7 @@ impl App {
|
||||
.store(false, std::sync::atomic::Ordering::Relaxed);
|
||||
if std::process::Command::new("python3")
|
||||
.arg("assemble_trace.py")
|
||||
.current_dir("tape-drive")
|
||||
.status()
|
||||
.is_err()
|
||||
{
|
||||
@@ -2590,7 +2591,7 @@ fn relpath(path: &str) -> PathBuf {
|
||||
}
|
||||
|
||||
fn read_spirv_words_from_file(name: &str) -> std::io::Result<Vec<u32>> {
|
||||
let mut file = std::fs::File::open(format!("shaders_out/{name}"))?;
|
||||
let mut file = std::fs::File::open(format!("tape-drive/shaders_out/{name}"))?;
|
||||
let mut bytes = vec![];
|
||||
file.read_to_end(&mut bytes).unwrap();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user