diff options
author | Liam <byteslice@airmail.cc> | 2024-02-14 22:29:24 +0100 |
---|---|---|
committer | Liam <byteslice@airmail.cc> | 2024-02-18 00:01:41 +0100 |
commit | dcce9837d240fa2492f29e5ae2649085ae8f711c (patch) | |
tree | 8a93012b952276e29fa63490b4183a57cf346878 /src/core/hle/service/vi/fbshare_buffer_manager.h | |
parent | nvnflinger: convert to process (diff) | |
download | yuzu-dcce9837d240fa2492f29e5ae2649085ae8f711c.tar yuzu-dcce9837d240fa2492f29e5ae2649085ae8f711c.tar.gz yuzu-dcce9837d240fa2492f29e5ae2649085ae8f711c.tar.bz2 yuzu-dcce9837d240fa2492f29e5ae2649085ae8f711c.tar.lz yuzu-dcce9837d240fa2492f29e5ae2649085ae8f711c.tar.xz yuzu-dcce9837d240fa2492f29e5ae2649085ae8f711c.tar.zst yuzu-dcce9837d240fa2492f29e5ae2649085ae8f711c.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/hle/service/vi/fbshare_buffer_manager.h (renamed from src/core/hle/service/nvnflinger/fb_share_buffer_manager.h) | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/src/core/hle/service/nvnflinger/fb_share_buffer_manager.h b/src/core/hle/service/vi/fbshare_buffer_manager.h index b79a7d23a..b9e99e61f 100644 --- a/src/core/hle/service/nvnflinger/fb_share_buffer_manager.h +++ b/src/core/hle/service/vi/fbshare_buffer_manager.h @@ -16,7 +16,7 @@ namespace Kernel { class KPageGroup; } -namespace Service::Nvnflinger { +namespace Service::VI { struct SharedMemorySlot { u64 buffer_offset; @@ -32,16 +32,17 @@ struct SharedMemoryPoolLayout { }; static_assert(sizeof(SharedMemoryPoolLayout) == 0x188, "SharedMemoryPoolLayout has wrong size"); -struct FbShareSession; +struct FbshareSession; -class FbShareBufferManager final { +class FbshareBufferManager final { public: - explicit FbShareBufferManager(Core::System& system, Nvnflinger& flinger, + explicit FbshareBufferManager(Core::System& system, + std::shared_ptr<Nvnflinger::Nvnflinger> surface_flinger, std::shared_ptr<Nvidia::Module> nvdrv); - ~FbShareBufferManager(); + ~FbshareBufferManager(); Result Initialize(Kernel::KProcess* owner_process, u64* out_buffer_id, u64* out_layer_handle, - u64 display_id, LayerBlending blending); + u64 display_id, Nvnflinger::LayerBlending blending); void Finalize(Kernel::KProcess* owner_process); Result GetSharedBufferMemoryHandleId(u64* out_buffer_size, s32* out_nvmap_handle, @@ -63,20 +64,20 @@ private: u64 m_display_id = 0; u64 m_buffer_id = 0; SharedMemoryPoolLayout m_pool_layout = {}; - std::map<u64, FbShareSession> m_sessions; + std::map<u64, FbshareSession> m_sessions; std::unique_ptr<Kernel::KPageGroup> m_buffer_page_group; std::mutex m_guard; Core::System& m_system; - Nvnflinger& m_flinger; - std::shared_ptr<Nvidia::Module> m_nvdrv; + const std::shared_ptr<Nvnflinger::Nvnflinger> m_surface_flinger; + const std::shared_ptr<Nvidia::Module> m_nvdrv; }; -struct FbShareSession { +struct FbshareSession { Nvidia::DeviceFD nvmap_fd = {}; Nvidia::NvCore::SessionId session_id = {}; u64 layer_id = {}; u32 buffer_nvmap_handle = 0; }; -} // namespace Service::Nvnflinger +} // namespace Service::VI |