summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/vi/application_display_service.h
diff options
context:
space:
mode:
authorLiam <byteslice@airmail.cc>2024-02-14 05:36:06 +0100
committerLiam <byteslice@airmail.cc>2024-02-14 18:03:32 +0100
commit2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14 (patch)
tree7c28b4f1b8d7bbbb7b363d5569d7dd70b34d146e /src/core/hle/service/vi/application_display_service.h
parentvi: extract types (diff)
downloadyuzu-2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14.tar
yuzu-2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14.tar.gz
yuzu-2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14.tar.bz2
yuzu-2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14.tar.lz
yuzu-2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14.tar.xz
yuzu-2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14.tar.zst
yuzu-2e8c0e9247bfcb5cdd0f4235bda5ee6f58b16c14.zip
Diffstat (limited to '')
-rw-r--r--src/core/hle/service/vi/application_display_service.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/src/core/hle/service/vi/application_display_service.h b/src/core/hle/service/vi/application_display_service.h
new file mode 100644
index 000000000..51ae2c472
--- /dev/null
+++ b/src/core/hle/service/vi/application_display_service.h
@@ -0,0 +1,48 @@
+// SPDX-FileCopyrightText: Copyright 2024 yuzu Emulator Project
+// SPDX-License-Identifier: GPL-2.0-or-later
+
+#include "core/hle/service/service.h"
+#include "core/hle/service/vi/vi_types.h"
+
+namespace Service::VI {
+
+class IApplicationDisplayService final : public ServiceFramework<IApplicationDisplayService> {
+public:
+ IApplicationDisplayService(Core::System& system_, Nvnflinger::Nvnflinger& nvnflinger_,
+ Nvnflinger::HosBinderDriverServer& hos_binder_driver_server_);
+ ~IApplicationDisplayService() override;
+
+private:
+ void GetRelayService(HLERequestContext& ctx);
+ void GetSystemDisplayService(HLERequestContext& ctx);
+ void GetManagerDisplayService(HLERequestContext& ctx);
+ void GetIndirectDisplayTransactionService(HLERequestContext& ctx);
+ void OpenDisplay(HLERequestContext& ctx);
+ void OpenDefaultDisplay(HLERequestContext& ctx);
+ void OpenDisplayImpl(HLERequestContext& ctx, std::string_view name);
+ void CloseDisplay(HLERequestContext& ctx);
+ void SetDisplayEnabled(HLERequestContext& ctx);
+ void GetDisplayResolution(HLERequestContext& ctx);
+ void SetLayerScalingMode(HLERequestContext& ctx);
+ void ListDisplays(HLERequestContext& ctx);
+ void OpenLayer(HLERequestContext& ctx);
+ void CloseLayer(HLERequestContext& ctx);
+ void CreateStrayLayer(HLERequestContext& ctx);
+ void DestroyStrayLayer(HLERequestContext& ctx);
+ void GetDisplayVsyncEvent(HLERequestContext& ctx);
+ void ConvertScalingMode(HLERequestContext& ctx);
+ void GetIndirectLayerImageMap(HLERequestContext& ctx);
+ void GetIndirectLayerImageRequiredMemoryInfo(HLERequestContext& ctx);
+
+private:
+ static Result ConvertScalingModeImpl(ConvertedScaleMode* out_scaling_mode,
+ NintendoScaleMode mode);
+
+private:
+ Nvnflinger::Nvnflinger& nvnflinger;
+ Nvnflinger::HosBinderDriverServer& hos_binder_driver_server;
+ std::vector<u64> stray_layer_ids;
+ bool vsync_event_fetched{false};
+};
+
+} // namespace Service::VI