mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-07-09 00:28:42 +12:00
metal: create renderer
This commit is contained in:
parent
98b5d56021
commit
58e1a53699
7 changed files with 34 additions and 8 deletions
|
@ -103,6 +103,7 @@ MainWindow::MainWindow(QApplication* app, QWidget* parent) : QMainWindow(parent)
|
|||
const RendererType rendererType = emu->getConfig().rendererType;
|
||||
usingGL = (rendererType == RendererType::OpenGL || rendererType == RendererType::Software || rendererType == RendererType::Null);
|
||||
usingVk = (rendererType == RendererType::Vulkan);
|
||||
usingMtl = (rendererType == RendererType::Metal);
|
||||
|
||||
if (usingGL) {
|
||||
// Make GL context current for this thread, enable VSync
|
||||
|
@ -113,6 +114,8 @@ MainWindow::MainWindow(QApplication* app, QWidget* parent) : QMainWindow(parent)
|
|||
emu->initGraphicsContext(glContext);
|
||||
} else if (usingVk) {
|
||||
Helpers::panic("Vulkan on Qt is currently WIP, try the SDL frontend instead!");
|
||||
} else if (usingMtl) {
|
||||
Helpers::panic("Metal on Qt currently doesn't work, try the SDL frontend instead!");
|
||||
} else {
|
||||
Helpers::panic("Unsupported graphics backend for Qt frontend!");
|
||||
}
|
||||
|
@ -628,4 +631,4 @@ void MainWindow::setupControllerSensors(SDL_GameController* controller) {
|
|||
if (haveGyro) {
|
||||
SDL_GameControllerSetSensorEnabled(controller, SDL_SENSOR_GYRO, SDL_TRUE);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue