MCPcopy Create free account
hub / github.com/SakuraEngine/SakuraEngine / SDLEventHandler

Function SDLEventHandler

samples/common/common/utils.h:17–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15#define BACK_BUFFER_HEIGHT 900
16
17inline static bool SDLEventHandler(const SDL_Event* event, SDL_Window* window)
18{
19 switch (event->type)
20 {
21 case SDL_WINDOWEVENT:
22 if (event->window.event == SDL_WINDOWEVENT_SIZE_CHANGED)
23 {
24 const int32_t ResizeWidth = event->window.data1;
25 const int32_t ResizeHeight = event->window.data2;
26 (void)ResizeWidth;
27 (void)ResizeHeight;
28 }
29 else if (event->window.event == SDL_WINDOWEVENT_CLOSE)
30 return false;
31 default:
32 return true;
33 }
34}
35
36inline static void read_bytes(const char8_t* file_name, uint32_t** bytes, uint32_t* length)
37{

Callers 9

raster_programFunction · 0.50
raster_programFunction · 0.50
raster_programFunction · 0.50
raster_programFunction · 0.50
raster_programFunction · 0.50
receiver_mainFunction · 0.50
provider_mainFunction · 0.50
mainFunction · 0.50
mainFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected