early-access version 3402
This commit is contained in:
parent
c2eefbe6b7
commit
9cb3261bb3
3 changed files with 4 additions and 14 deletions
|
@ -1,7 +1,7 @@
|
||||||
yuzu emulator early access
|
yuzu emulator early access
|
||||||
=============
|
=============
|
||||||
|
|
||||||
This is the source code for early-access 3401.
|
This is the source code for early-access 3402.
|
||||||
|
|
||||||
## Legal Notice
|
## Legal Notice
|
||||||
|
|
||||||
|
|
|
@ -152,6 +152,8 @@ bool Codec::CreateGpuAvDevice() {
|
||||||
void Codec::InitializeAvCodecContext() {
|
void Codec::InitializeAvCodecContext() {
|
||||||
av_codec_ctx = avcodec_alloc_context3(av_codec);
|
av_codec_ctx = avcodec_alloc_context3(av_codec);
|
||||||
av_opt_set(av_codec_ctx->priv_data, "tune", "zerolatency", 0);
|
av_opt_set(av_codec_ctx->priv_data, "tune", "zerolatency", 0);
|
||||||
|
av_codec_ctx->thread_count = 0;
|
||||||
|
av_codec_ctx->thread_type &= ~FF_THREAD_FRAME;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Codec::InitializeGpuDecoder() {
|
void Codec::InitializeGpuDecoder() {
|
||||||
|
|
|
@ -3167,20 +3167,8 @@ void GMainWindow::ShowFullscreen() {
|
||||||
window->hide();
|
window->hide();
|
||||||
window->setWindowFlags(window->windowFlags() | Qt::FramelessWindowHint);
|
window->setWindowFlags(window->windowFlags() | Qt::FramelessWindowHint);
|
||||||
const auto screen_geometry = GuessCurrentScreen(window)->geometry();
|
const auto screen_geometry = GuessCurrentScreen(window)->geometry();
|
||||||
// NB: On Windows, a borderless window will be treated the same as exclusive fullscreen
|
|
||||||
// when the window geometry matches the physical dimensions of the screen.
|
|
||||||
// However, with High DPI scaling, when the devicePixelRatioF() is > 1, the borderless
|
|
||||||
// window apparently is not treated as exclusive fullscreen and functions correctly.
|
|
||||||
// One can verify and replicate this behavior by using a high resolution (4K) display,
|
|
||||||
// and switching between 100% and 200% scaling in Windows' display settings.
|
|
||||||
// At 100%, without the addition of 1, it is treated as exclusive fullscreen.
|
|
||||||
// At 200%, with or without the addition of 1, it is treated as borderless windowed.
|
|
||||||
// Therefore, we can use (read: abuse) this difference in behavior to fix this issue for
|
|
||||||
// those with higher resolution displays when the Qt scaling ratio is > 1.
|
|
||||||
// Should this behavior be changed in the future, please revisit this workaround.
|
|
||||||
const bool must_add_one = devicePixelRatioF() == 1.0f;
|
|
||||||
window->setGeometry(screen_geometry.x(), screen_geometry.y(), screen_geometry.width(),
|
window->setGeometry(screen_geometry.x(), screen_geometry.y(), screen_geometry.width(),
|
||||||
screen_geometry.height() + (must_add_one ? 1 : 0));
|
screen_geometry.height() + 1);
|
||||||
window->raise();
|
window->raise();
|
||||||
window->showNormal();
|
window->showNormal();
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue