mirror of https://github.com/mgba-emu/mgba.git
Qt: Fix GL scaling
This commit is contained in:
parent
838d13f2ef
commit
bdb584a398
|
@ -86,6 +86,7 @@ CoreController::CoreController(mCore* core, QObject* parent)
|
||||||
context->core->setVideoBuffer(context->core, reinterpret_cast<color_t*>(controller->m_activeBuffer->data()), controller->screenDimensions().width());
|
context->core->setVideoBuffer(context->core, reinterpret_cast<color_t*>(controller->m_activeBuffer->data()), controller->screenDimensions().width());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QMetaObject::invokeMethod(controller, "didReset");
|
||||||
controller->finishFrame();
|
controller->finishFrame();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -170,6 +170,7 @@ signals:
|
||||||
void crashed(const QString& errorMessage);
|
void crashed(const QString& errorMessage);
|
||||||
void failed();
|
void failed();
|
||||||
void frameAvailable();
|
void frameAvailable();
|
||||||
|
void didReset();
|
||||||
void stateLoaded();
|
void stateLoaded();
|
||||||
void rewound();
|
void rewound();
|
||||||
|
|
||||||
|
|
|
@ -108,6 +108,7 @@ void DisplayGL::startDrawing(std::shared_ptr<CoreController> controller) {
|
||||||
messagePainter()->resize(size(), isAspectRatioLocked(), devicePixelRatio());
|
messagePainter()->resize(size(), isAspectRatioLocked(), devicePixelRatio());
|
||||||
#endif
|
#endif
|
||||||
resizePainter();
|
resizePainter();
|
||||||
|
connect(m_context.get(), &CoreController::didReset, this, &DisplayGL::resizeContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DisplayGL::stopDrawing() {
|
void DisplayGL::stopDrawing() {
|
||||||
|
|
Loading…
Reference in New Issue