Skip to content

Commit

Permalink
Qt: Fix GL scaling
Browse files Browse the repository at this point in the history
  • Loading branch information
endrift committed May 21, 2019
1 parent 838d13f commit bdb584a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/platform/qt/CoreController.cpp
Expand Up @@ -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();
};

Expand Down
1 change: 1 addition & 0 deletions src/platform/qt/CoreController.h
Expand Up @@ -170,6 +170,7 @@ public slots:
void crashed(const QString& errorMessage);
void failed();
void frameAvailable();
void didReset();
void stateLoaded();
void rewound();

Expand Down
1 change: 1 addition & 0 deletions src/platform/qt/DisplayGL.cpp
Expand Up @@ -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() {
Expand Down

0 comments on commit bdb584a

Please sign in to comment.