Skip to content

Commit

Permalink
igl | third-party | Fix nanovg.py
Browse files Browse the repository at this point in the history
  • Loading branch information
vinsentli committed Dec 19, 2024
1 parent 7c5ce8c commit 65cd2c5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion third-party/deps/patches/nanovg.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,14 @@

file = Path(os.path.join(lib_dir, "example/demo.c"))
file.write_text(file.read_text()
.replace("#include <GLFW/glfw3.h>", "")
.replace("#include <GLFW/glfw3.h>", "#include <stdlib.h>")
.replace("#define STB_IMAGE_WRITE_IMPLEMENTATION", "")
.replace("glReadPixels(0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE, image);", "// glReadPixels(0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE, image);")
)

file = Path(os.path.join(lib_dir, "example/perf.c"))
file.write_text(file.read_text()
.replace("#include <GLFW/glfw3.h>", "")
.replace("void startGPUTimer(GPUtimer* timer)",
("""#if 0
void startGPUTimer(GPUtimer* timer)
Expand Down

0 comments on commit 65cd2c5

Please sign in to comment.