PixelBullet
0.0.1
A C++ game engine
Loading...
Searching...
No Matches
engine
src
window
glfw
runtime_internal.h
1
#pragma once
2
3
#include <cstdint>
4
5
namespace
pixelbullet::glfw_runtime_internal
6
{
7
using
ErrorCallback = void (*)(int,
const
char
*);
8
9
struct
RuntimeState
10
{
11
unsigned
int
window_count = 0;
12
unsigned
int
next_window_id = 0;
13
};
14
15
class
Platform
16
{
17
public
:
18
virtual
~Platform
() =
default
;
19
20
virtual
void
SetErrorCallback(ErrorCallback callback) = 0;
21
[[nodiscard]]
virtual
bool
Init() = 0;
22
[[nodiscard]]
virtual
bool
VulkanSupported() = 0;
23
virtual
void
Terminate() = 0;
24
};
25
26
void
Acquire(
RuntimeState
& state,
Platform
& platform);
27
void
Release(
RuntimeState
& state,
Platform
& platform)
noexcept
;
28
[[nodiscard]]
unsigned
int
NextWindowId(
RuntimeState
& state)
noexcept
;
29
}
// namespace pixelbullet::glfw_runtime_internal
pixelbullet::glfw_runtime_internal::Platform
Definition
runtime_internal.h:16
pixelbullet::glfw_runtime_internal::RuntimeState
Definition
runtime_internal.h:10
Generated by
1.16.1