summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/vi/vi.cpp
diff options
context:
space:
mode:
authormailwl <mailwl@gmail.com>2018-04-16 11:04:34 +0200
committermailwl <mailwl@gmail.com>2018-04-17 18:42:14 +0200
commit5922f2c46da6f47c6537af6d717c355e81cca727 (patch)
tree9681d987f8d6e021ce004e81dbf4e031f62d1d11 /src/core/hle/service/vi/vi.cpp
parentMerge pull request #343 from Subv/tex_wrap_4 (diff)
downloadyuzu-5922f2c46da6f47c6537af6d717c355e81cca727.tar
yuzu-5922f2c46da6f47c6537af6d717c355e81cca727.tar.gz
yuzu-5922f2c46da6f47c6537af6d717c355e81cca727.tar.bz2
yuzu-5922f2c46da6f47c6537af6d717c355e81cca727.tar.lz
yuzu-5922f2c46da6f47c6537af6d717c355e81cca727.tar.xz
yuzu-5922f2c46da6f47c6537af6d717c355e81cca727.tar.zst
yuzu-5922f2c46da6f47c6537af6d717c355e81cca727.zip
Diffstat (limited to '')
-rw-r--r--src/core/hle/service/vi/vi.cpp34
1 files changed, 27 insertions, 7 deletions
diff --git a/src/core/hle/service/vi/vi.cpp b/src/core/hle/service/vi/vi.cpp
index 7c319ee67..d938ef83d 100644
--- a/src/core/hle/service/vi/vi.cpp
+++ b/src/core/hle/service/vi/vi.cpp
@@ -587,7 +587,7 @@ public:
{2203, nullptr, "SetLayerSize"},
{2204, nullptr, "GetLayerZ"},
{2205, &ISystemDisplayService::SetLayerZ, "SetLayerZ"},
- {2207, nullptr, "SetLayerVisibility"},
+ {2207, &ISystemDisplayService::SetLayerVisibility, "SetLayerVisibility"},
{2209, nullptr, "SetLayerAlpha"},
{2312, nullptr, "CreateStrayLayer"},
{2400, nullptr, "OpenIndirectLayer"},
@@ -637,6 +637,16 @@ private:
IPC::ResponseBuilder rb = rp.MakeBuilder(2, 0, 0);
rb.Push(RESULT_SUCCESS);
}
+
+ void SetLayerVisibility(Kernel::HLERequestContext& ctx) {
+ IPC::RequestParser rp{ctx};
+ u64 layer_id = rp.Pop<u64>();
+ bool visibility = rp.Pop<bool>();
+ IPC::ResponseBuilder rb = rp.MakeBuilder(2, 0, 0);
+ rb.Push(RESULT_SUCCESS);
+ LOG_WARNING(Service_VI, "(STUBBED) called, layer_id=0x%x, visibility=%u", layer_id,
+ visibility);
+ }
};
class IManagerDisplayService final : public ServiceFramework<IManagerDisplayService> {
@@ -668,7 +678,7 @@ public:
{4206, nullptr, "SetDefaultDisplay"},
{6000, &IManagerDisplayService::AddToLayerStack, "AddToLayerStack"},
{6001, nullptr, "RemoveFromLayerStack"},
- {6002, nullptr, "SetLayerVisibility"},
+ {6002, &IManagerDisplayService::SetLayerVisibility, "SetLayerVisibility"},
{6003, nullptr, "SetLayerConfig"},
{6004, nullptr, "AttachLayerPresentationTracer"},
{6005, nullptr, "DetachLayerPresentationTracer"},
@@ -750,6 +760,16 @@ private:
rb.Push(RESULT_SUCCESS);
}
+ void SetLayerVisibility(Kernel::HLERequestContext& ctx) {
+ IPC::RequestParser rp{ctx};
+ u64 layer_id = rp.Pop<u64>();
+ bool visibility = rp.Pop<bool>();
+ IPC::ResponseBuilder rb = rp.MakeBuilder(2, 0, 0);
+ rb.Push(RESULT_SUCCESS);
+ LOG_WARNING(Service_VI, "(STUBBED) called, layer_id=0x%x, visibility=%u", layer_id,
+ visibility);
+ }
+
std::shared_ptr<NVFlinger::NVFlinger> nv_flinger;
};
@@ -820,15 +840,15 @@ private:
IPC::RequestParser rp{ctx};
u64 display_id = rp.Pop<u64>();
- IPC::ResponseBuilder rb = rp.MakeBuilder(4, 0, 0);
+ IPC::ResponseBuilder rb = rp.MakeBuilder(6, 0, 0);
rb.Push(RESULT_SUCCESS);
if (Settings::values.use_docked_mode) {
- rb.Push(static_cast<u32>(DisplayResolution::DockedWidth));
- rb.Push(static_cast<u32>(DisplayResolution::DockedHeight));
+ rb.Push(static_cast<u64>(DisplayResolution::DockedWidth));
+ rb.Push(static_cast<u64>(DisplayResolution::DockedHeight));
} else {
- rb.Push(static_cast<u32>(DisplayResolution::UndockedWidth));
- rb.Push(static_cast<u32>(DisplayResolution::UndockedHeight));
+ rb.Push(static_cast<u64>(DisplayResolution::UndockedWidth));
+ rb.Push(static_cast<u64>(DisplayResolution::UndockedHeight));
}
}