2023-01-29 00:04:24 +00:00
|
|
|
/************************************************************//**
|
|
|
|
*
|
|
|
|
* @file: milepost.c
|
|
|
|
* @author: Martin Fouilleul
|
|
|
|
* @date: 13/02/2021
|
|
|
|
* @revision:
|
|
|
|
*
|
|
|
|
*****************************************************************/
|
|
|
|
|
|
|
|
//---------------------------------------------------------------
|
|
|
|
// utilities implementations
|
|
|
|
//---------------------------------------------------------------
|
|
|
|
#include"util/debug_log.c"
|
|
|
|
#include"util/memory.c"
|
|
|
|
#include"util/strings.c"
|
|
|
|
#include"util/utf8.c"
|
|
|
|
#include"util/hash.c"
|
|
|
|
#include"util/ringbuffer.c"
|
|
|
|
|
|
|
|
//---------------------------------------------------------------
|
|
|
|
// platform implementations
|
|
|
|
//---------------------------------------------------------------
|
|
|
|
#include"platform.h"
|
|
|
|
|
|
|
|
#if defined(OS_WIN64)
|
|
|
|
#include"platform/win32_base_allocator.c"
|
2023-02-03 17:44:28 +00:00
|
|
|
#include"platform/win32_clock.c"
|
2023-01-29 00:04:24 +00:00
|
|
|
//TODO
|
|
|
|
#elif defined(OS_MACOS)
|
|
|
|
#include"platform/unix_base_allocator.c"
|
|
|
|
#include"platform/osx_clock.c"
|
|
|
|
/*
|
|
|
|
#include"platform/unix_rng.c"
|
|
|
|
#include"platform/posix_thread.c"
|
|
|
|
#include"platform/posix_socket.c"
|
|
|
|
*/
|
|
|
|
|
|
|
|
#elif defined(OS_LINUX)
|
|
|
|
#include"platform/unix_base_allocator.c"
|
|
|
|
#include"platform/linux_clock.c"
|
|
|
|
/*
|
|
|
|
#include"platform/unix_rng.c"
|
|
|
|
#include"platform/posix_thread.c"
|
|
|
|
#include"platform/posix_socket.c"
|
|
|
|
*/
|
|
|
|
#else
|
|
|
|
#error "Unsupported platform"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
//---------------------------------------------------------------
|
2023-02-10 15:56:10 +00:00
|
|
|
// app/graphics layer
|
2023-01-29 00:04:24 +00:00
|
|
|
//---------------------------------------------------------------
|
|
|
|
|
|
|
|
#if defined(OS_WIN64)
|
|
|
|
#include"win32_app.c"
|
2023-02-10 15:56:10 +00:00
|
|
|
#include"graphics.c"
|
|
|
|
|
2023-02-17 17:56:16 +00:00
|
|
|
#if MG_COMPILE_BACKEND_GL || MG_COMPILE_BACKEND_GLES
|
|
|
|
#include"gl_loader.c"
|
|
|
|
#endif
|
|
|
|
|
2023-02-10 15:56:10 +00:00
|
|
|
#if MG_COMPILE_BACKEND_GL
|
2023-02-20 17:34:29 +00:00
|
|
|
#include"wgl_surface.c"
|
2023-02-10 15:56:10 +00:00
|
|
|
#include"gl_canvas.c"
|
2023-02-17 17:56:16 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
#if MG_COMPILE_BACKEND_GLES
|
2023-02-21 11:35:22 +00:00
|
|
|
#include"egl_surface.c"
|
2023-02-10 15:56:10 +00:00
|
|
|
#endif
|
|
|
|
|
2023-01-29 00:04:24 +00:00
|
|
|
#elif defined(OS_MACOS)
|
2023-02-10 15:56:10 +00:00
|
|
|
//NOTE: macos application layer and graphics backends are defined in milepost.m
|
2023-01-29 00:04:24 +00:00
|
|
|
#else
|
|
|
|
#error "Unsupported platform"
|
|
|
|
#endif
|