summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorFernando Sahmkow <fsahmkow27@gmail.com>2019-09-26 21:41:10 +0200
committerFernandoS27 <fsahmkow27@gmail.com>2019-10-05 01:59:51 +0200
commit782b7a0ca45b08d981e48a6d9a7af73cbed13281 (patch)
tree256d95e8f8648e71c23fe8ce0d533de952a84a79 /src
parentNvdrv: Do framelimiting only in the CPU Thread (diff)
downloadyuzu-782b7a0ca45b08d981e48a6d9a7af73cbed13281.tar
yuzu-782b7a0ca45b08d981e48a6d9a7af73cbed13281.tar.gz
yuzu-782b7a0ca45b08d981e48a6d9a7af73cbed13281.tar.bz2
yuzu-782b7a0ca45b08d981e48a6d9a7af73cbed13281.tar.lz
yuzu-782b7a0ca45b08d981e48a6d9a7af73cbed13281.tar.xz
yuzu-782b7a0ca45b08d981e48a6d9a7af73cbed13281.tar.zst
yuzu-782b7a0ca45b08d981e48a6d9a7af73cbed13281.zip
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/service/nvflinger/nvflinger.cpp19
-rw-r--r--src/core/hle/service/nvflinger/nvflinger.h2
2 files changed, 1 insertions, 20 deletions
diff --git a/src/core/hle/service/nvflinger/nvflinger.cpp b/src/core/hle/service/nvflinger/nvflinger.cpp
index 3c08ac9a3..6eee20efe 100644
--- a/src/core/hle/service/nvflinger/nvflinger.cpp
+++ b/src/core/hle/service/nvflinger/nvflinger.cpp
@@ -174,19 +174,8 @@ const VI::Layer* NVFlinger::FindLayer(u64 display_id, u64 layer_id) const {
void NVFlinger::Compose() {
for (auto& display : displays) {
- bool trigger_event = false;
// Trigger vsync for this display at the end of drawing
- SCOPE_EXIT({
- // TODO(Blinkhawk): Correctly send buffers through nvflinger while
- // loading the game thorugh the OS.
- // During loading, the OS takes care of sending buffers to vsync,
- // thus it triggers, since this is not properly emulated due to
- // HLE complications, we allow it to signal until the game enqueues
- // it's first buffer.
- if (trigger_event || !first_buffer_enqueued) {
- display.SignalVSyncEvent();
- }
- });
+ SCOPE_EXIT({ display.SignalVSyncEvent(); });
// Don't do anything for displays without layers.
if (!display.HasLayers())
@@ -202,16 +191,10 @@ void NVFlinger::Compose() {
MicroProfileFlip();
if (!buffer) {
- // There was no queued buffer to draw, render previous frame
- auto& gpu = system.GPU();
- // Always trigger on sync GPU.
- trigger_event = !gpu.IsAsync();
continue;
}
const auto& igbp_buffer = buffer->get().igbp_buffer;
- trigger_event = true;
- first_buffer_enqueued = true;
const auto& gpu = system.GPU();
const auto& multi_fence = buffer->get().multi_fence;
diff --git a/src/core/hle/service/nvflinger/nvflinger.h b/src/core/hle/service/nvflinger/nvflinger.h
index 95d7278f5..5d7e3bfb8 100644
--- a/src/core/hle/service/nvflinger/nvflinger.h
+++ b/src/core/hle/service/nvflinger/nvflinger.h
@@ -102,8 +102,6 @@ private:
u32 swap_interval = 1;
- bool first_buffer_enqueued{};
-
/// Event that handles screen composition.
Core::Timing::EventType* composition_event;