Qt: Fix GL scaling

This commit is contained in:
Vicki Pfau 2019-05-20 19:12:45 -07:00
parent 838d13f2ef
commit bdb584a398
3 changed files with 3 additions and 0 deletions

View File

@ -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());
}
QMetaObject::invokeMethod(controller, "didReset");
controller->finishFrame();
};

View File

@ -170,6 +170,7 @@ signals:
void crashed(const QString& errorMessage);
void failed();
void frameAvailable();
void didReset();
void stateLoaded();
void rewound();

View File

@ -108,6 +108,7 @@ void DisplayGL::startDrawing(std::shared_ptr<CoreController> controller) {
messagePainter()->resize(size(), isAspectRatioLocked(), devicePixelRatio());
#endif
resizePainter();
connect(m_context.get(), &CoreController::didReset, this, &DisplayGL::resizeContext);
}
void DisplayGL::stopDrawing() {