mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-22 22:00:39 -06:00
Initial support for Haiku.
This commit is contained in:
30
Source/Core/Common/GL/GLInterface/EGLHaiku.cpp
Normal file
30
Source/Core/Common/GL/GLInterface/EGLHaiku.cpp
Normal file
@ -0,0 +1,30 @@
|
||||
// Copyright 2017 Dolphin Emulator Project
|
||||
// Licensed under GPLv2+
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
#include "Common/GL/GLInterface/EGLHaiku.h"
|
||||
|
||||
#include <Window.h>
|
||||
|
||||
EGLDisplay cInterfaceEGLHaiku::OpenDisplay()
|
||||
{
|
||||
return eglGetDisplay(EGL_DEFAULT_DISPLAY);
|
||||
}
|
||||
|
||||
EGLNativeWindowType cInterfaceEGLHaiku::InitializePlatform(EGLNativeWindowType host_window,
|
||||
EGLConfig config)
|
||||
{
|
||||
EGLint format;
|
||||
eglGetConfigAttrib(egl_dpy, config, EGL_NATIVE_VISUAL_ID, &format);
|
||||
|
||||
BWindow* window = reinterpret_cast<BWindow*>(host_window);
|
||||
const int width = window->Size().width;
|
||||
const int height = window->Size().height;
|
||||
GLInterface->SetBackBufferDimensions(width, height);
|
||||
|
||||
return host_window;
|
||||
}
|
||||
|
||||
void cInterfaceEGLHaiku::ShutdownPlatform()
|
||||
{
|
||||
}
|
Reference in New Issue
Block a user