summaryrefslogtreecommitdiff
path: root/examples/obj_loading
diff options
context:
space:
mode:
authorJoshua Rowe <17525998+omnisci3nce@users.noreply.github.com>2024-05-20 10:50:11 +1000
committerGitHub <noreply@github.com>2024-05-20 10:50:11 +1000
commite904c22003c3a134201b222e6619e782fbe63947 (patch)
tree5295c8ce5f855ca4a0f1bebe50beee80bae66682 /examples/obj_loading
parent02e84ee4d18e705e3362be1e327fdb6f1397a032 (diff)
parent73d4145f46d2305f45761b8e456df692d1962dfb (diff)
Merge pull request #14 from omnisci3nce/realign
Realign
Diffstat (limited to 'examples/obj_loading')
-rw-r--r--examples/obj_loading/ex_obj_loading.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/obj_loading/ex_obj_loading.c b/examples/obj_loading/ex_obj_loading.c
index e225cb2..906816b 100644
--- a/examples/obj_loading/ex_obj_loading.c
+++ b/examples/obj_loading/ex_obj_loading.c
@@ -1,3 +1,4 @@
+#include <assert.h>
#include <glfw3.h>
#include <string.h>
@@ -25,6 +26,7 @@ int main() {
model_handle backpack_handle =
model_load_obj(core, "assets/models/obj/backpack/backpack.obj", true);
model* backpack = &core->models->data[backpack_handle.raw];
+ assert(backpack->meshes->data->is_skinned == false);
// 2. upload vertex data to gpu
model_upload_meshes(&core->renderer, backpack);
// 3. create a camera
@@ -53,7 +55,7 @@ int main() {
memcpy(&our_scene.point_lights, &point_lights, sizeof(point_light[4]));
// --- Enter Main loop
- while (!glfwWindowShouldClose(core->renderer.window)) {
+ while (!should_exit(core)) {
input_update(&core->input);
threadpool_process_results(&core->threadpool, 1);