Basic 3D rendering
This commit is contained in:
19
src/game.h
19
src/game.h
@@ -1,12 +1,31 @@
|
||||
#pragma once
|
||||
|
||||
#include <stdbool.h>
|
||||
#include "SDL2/SDL.h"
|
||||
#include "cglm/cglm.h"
|
||||
#include "camera.h"
|
||||
#include "shape.h"
|
||||
|
||||
typedef struct
|
||||
{
|
||||
bool w;
|
||||
bool a;
|
||||
bool s;
|
||||
bool d;
|
||||
} InputState;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
bool running;
|
||||
InputState input;
|
||||
SDL_Window *window;
|
||||
SDL_GLContext *glContext;
|
||||
GLuint textureId;
|
||||
int shaderProgramId;
|
||||
Camera camera;
|
||||
Shape *testShape;
|
||||
mat4 projMatrix;
|
||||
mat4 viewMatrix;
|
||||
} GameState;
|
||||
|
||||
GameState *Game_New();
|
||||
|
||||
Reference in New Issue
Block a user