From be63cdf390b0bdbb00ba67cff95d165d214418fb Mon Sep 17 00:00:00 2001 From: 3gg <3gg@shellblade.net> Date: Sat, 17 Jun 2023 20:37:26 -0700 Subject: Allow plugins to not have to define all plugin functions. --- gltfview/src/plugins/texture_view.c | 22 +--------------------- gltfview/src/plugins/texture_view.h | 6 ------ 2 files changed, 1 insertion(+), 27 deletions(-) (limited to 'gltfview/src/plugins') diff --git a/gltfview/src/plugins/texture_view.c b/gltfview/src/plugins/texture_view.c index f2c650f..2bca4a1 100644 --- a/gltfview/src/plugins/texture_view.c +++ b/gltfview/src/plugins/texture_view.c @@ -1,6 +1,7 @@ #include "texture_view.h" #include +#include #include #include #include @@ -13,15 +14,7 @@ // Default texture to load if no texture is provided. static const char* CLOUDS1_TEXTURE = "/assets/skybox/clouds1/clouds1_west.bmp"; -State* init(Game* game) { - assert(game); - - State* state = calloc(1, sizeof(State)); - return state; -} - bool boot(State* state, Game* game) { - assert(state); assert(game); // Usage: [texture file] @@ -37,9 +30,6 @@ bool boot(State* state, Game* game) { .mipmaps = false, .data.texture.filepath = mstring_make(texture_file)}); - Camera* camera = gfx_get_camera_camera(game->camera); - spatial3_set_position(&camera->spatial, vec3_make(0, 0, 1)); - ShaderProgram* shader = gfx_make_view_texture_shader(render_backend); if (!shader) { return false; @@ -82,13 +72,3 @@ bool boot(State* state, Game* game) { return true; } - -void update(State* state, Game* game, double t, double dt) { - assert(state); - assert(game); -} - -void render(State* state, const Game* game) { - assert(state); - assert(game); -} diff --git a/gltfview/src/plugins/texture_view.h b/gltfview/src/plugins/texture_view.h index 670d88d..956f34a 100644 --- a/gltfview/src/plugins/texture_view.h +++ b/gltfview/src/plugins/texture_view.h @@ -1,9 +1,3 @@ #pragma once #include "plugin.h" - -#include - -typedef struct State { - int unused; -} State; -- cgit v1.2.3