diff options
Diffstat (limited to 'examples')
-rw-r--r-- | examples/gltf_loading/ex_gltf_loading.c | 14 | ||||
-rw-r--r-- | examples/transforms/ex_transforms.c | 2 |
2 files changed, 6 insertions, 10 deletions
diff --git a/examples/gltf_loading/ex_gltf_loading.c b/examples/gltf_loading/ex_gltf_loading.c index 900cf1b..fa74ada 100644 --- a/examples/gltf_loading/ex_gltf_loading.c +++ b/examples/gltf_loading/ex_gltf_loading.c @@ -25,12 +25,10 @@ int main() { core* core = core_bringup(); - model_handle cube_handle = + model_handle helmet_handle = model_load_gltf(core, "assets/models/gltf/DamagedHelmet/glTF/DamagedHelmet.gltf", false); - // model_handle cube_handle = model_load_gltf(core, "assets/models/gltf/scifi_girl/scene.gltf", - // false); - model* cube = &core->models->data[cube_handle.raw]; - model_upload_meshes(&core->renderer, cube); + model* helmet = &core->models->data[helmet_handle.raw]; + model_upload_meshes(&core->renderer, helmet); vec3 camera_pos = vec3(5., 0., 0.); vec3 camera_front = vec3_normalise(vec3_negate(camera_pos)); @@ -61,7 +59,6 @@ int main() { deltaTime = currentFrame - lastFrame; lastFrame = currentFrame; input_update(&core->input); - // threadpool_process_results(&core->threadpool, 1); render_frame_begin(&core->renderer); @@ -70,10 +67,9 @@ int main() { static f32 rot_speed = 0.5; quat rot = quat_from_axis_angle(VEC3_Z, fmod(angle, TAU), true); angle += (rot_speed * deltaTime); - transform model_tf = transform_create(vec3(0.0, 0.1, -0.1), rot, - 1.8); // make the backpack a bit bigger + transform model_tf = transform_create(vec3(0.0, 0.1, -0.1), rot, 1.8); mat4 model = transform_to_mat(&model_tf); - draw_model(&core->renderer, &cam, cube, &model, &our_scene); + draw_model(&core->renderer, &cam, helmet, &model, &our_scene); render_frame_end(&core->renderer); } diff --git a/examples/transforms/ex_transforms.c b/examples/transforms/ex_transforms.c index 689c49d..fc225b4 100644 --- a/examples/transforms/ex_transforms.c +++ b/examples/transforms/ex_transforms.c @@ -5,7 +5,7 @@ #include "maths_types.h" #include "mem.h" #include "render.h" -#include "render_types.h" +// #include "render_types.h" #include "transform_hierarchy.h" const vec3 pointlight_positions[4] = { |