24#ifdef GPUCA_BUILD_EVENT_DISPLAY_X11
27#ifdef GPUCA_BUILD_EVENT_DISPLAY_GLFW
30#ifdef GPUCA_BUILD_EVENT_DISPLAY_GLUT
33#ifdef GPUCA_BUILD_EVENT_DISPLAY_WAYLAND
41#ifdef GPUCA_BUILD_EVENT_DISPLAY_QT
59 int32_t
retVal = me->FrontendMain();
61 me->InitDisplay(
true);
63 return ((
void*)(size_t)
retVal);
93#ifdef GPUCA_BUILD_EVENT_DISPLAY_QT
103#ifdef GPUCA_BUILD_EVENT_DISPLAY_QT
107 if (!
mGUI->isRunning()) {
119#ifdef GPUCA_BUILD_EVENT_DISPLAY_QT
127#if !defined(GPUCA_STANDALONE) && defined(GPUCA_BUILD_EVENT_DISPLAY_GLFW)
128 if (strcmp(
type,
"glfw") == 0 || strcmp(
type,
"auto") == 0) {
133 if (strcmp(
type,
"windows") == 0 || strcmp(
type,
"auto") == 0) {
136#elif defined(GPUCA_BUILD_EVENT_DISPLAY_X11)
137 if (strcmp(
type,
"x11") == 0 || strcmp(
type,
"auto") == 0) {
141#if defined(GPUCA_STANDALONE) && defined(GPUCA_BUILD_EVENT_DISPLAY_GLFW)
142 if (strcmp(
type,
"glfw") == 0 || strcmp(
type,
"auto") == 0) {
146#ifdef GPUCA_BUILD_EVENT_DISPLAY_WAYLAND
147 if (strcmp(
type,
"wayland") == 0 || (strcmp(
type,
"auto") == 0 && getenv(
"XDG_SESSION_TYPE") && strcmp(getenv(
"XDG_SESSION_TYPE"),
"wayland") == 0)) {
151#ifdef GPUCA_BUILD_EVENT_DISPLAY_GLUT
152 if (strcmp(
type,
"glut") == 0 || strcmp(
type,
"auto") == 0) {
156 if (strcmp(
type,
"none") == 0) {
159 GPUError(
"Requested frontend not available");
179 GPUError(
"Coult not Create frontend Thread...");
184 if ((hThread = CreateThread(
nullptr,
nullptr, &OpenGLWrapper,
this,
nullptr,
nullptr)) ==
nullptr) {
185 GPUError(
"Coult not Create GL Thread...");
std::unique_ptr< GPUDisplayGUIWrapper > mGUI
int32_t & drawTextFontSize()
~GPUDisplayFrontend() override
static void * FrontendThreadWrapper(void *)
void HandleKey(uint8_t key)
static GPUDisplayFrontend * getFrontend(const char *type)
void ResizeScene(int32_t width, int32_t height)
bool EnableSendKey() override
int32_t InitDisplay(bool initFailure=false)
GPUDisplayBackend * backend()
volatile int32_t mSendKey
void HandleKey(uint8_t key)
void HandleSendKey(int32_t key)
int32_t & drawTextFontSize()
int32_t InitDisplay(bool initFailure=false)
GPUDisplayBackend * backend() const
void ResizeScene(int32_t width, int32_t height, bool init=false)
GLint GLsizei GLsizei height
GLint GLint GLsizei GLint GLenum GLenum type