archeus/include/arc/engine/engine.h
2022-12-20 00:50:55 -07:00

46 lines
1 KiB
C

#ifndef ARC_ENGINE_H_
#define ARC_ENGINE_H_
#ifdef __cplusplus
extern "C" {
#endif
#include "arc/graphics/window.h"
#include "arc/graphics/renderer.h"
#include "arc/input/mouse.h"
#include "arc/input/keyboard.h"
#include "arc/std/handler.h"
#include "arc/math/point.h"
typedef struct ARC_EngineData {
ARC_Window *window;
ARC_Renderer *renderer;
ARC_Handler *state;
ARC_Mouse *mouse;
ARC_Keyboard *keyboard;
double dt;
uint32_t running;
ARC_Point windowSize;
} ARC_EngineData;
//NOTE: most work below is temp, and will change once I figure out a better way to write this header
void ARC_EngineData_Create(ARC_EngineData **data, ARC_Handler_CleanDataFn cleanfn, ARC_Point windowSize);
void ARC_EngineData_Destroy(ARC_EngineData *data);
/**
* @brief runs ARC_Engine
*
* @param data engine data that will be used
* data must be created before this function
* and must be destroyed after this function
*/
void ARC_Engine_Run(ARC_EngineData *data);
#ifdef __cplusplus
}
#endif
#endif // !ARC_ENGINE_H_