mirror of
https://github.com/KytyPS5/KytyPS5.git
synced 2026-10-21 19:36:55 +02:00
52 lines
1.5 KiB
C++
52 lines
1.5 KiB
C++
#ifndef EMULATOR_SRC_GRAPHICS_PRESENTATION_SYSTEMOVERLAY_H_
|
|
#define EMULATOR_SRC_GRAPHICS_PRESENTATION_SYSTEMOVERLAY_H_
|
|
|
|
#include "common/common.h"
|
|
#include "graphics/host_gpu/vulkanCommon.h"
|
|
|
|
#include <cstddef>
|
|
#include <filesystem>
|
|
#include <memory>
|
|
#include <span>
|
|
#include <string_view>
|
|
|
|
union SDL_Event;
|
|
struct SDL_Window;
|
|
|
|
namespace Libs::Graphics {
|
|
|
|
struct GraphicContext;
|
|
|
|
struct SystemOverlayVisualState {
|
|
bool active;
|
|
uint64_t revision;
|
|
};
|
|
|
|
void InitializeSplashScreen(const std::filesystem::path& sce_sys);
|
|
void HideSplashScreen();
|
|
void InitializeSystemOverlayInput(SDL_Window* window);
|
|
void ShutdownSystemOverlayInput();
|
|
bool ProcessSystemOverlayInput(const SDL_Event& event);
|
|
SystemOverlayVisualState GetSystemOverlayVisualState() noexcept;
|
|
void NotifyTrophyUnlocked(std::string_view name, int32_t grade,
|
|
std::span<const std::byte> icon_png);
|
|
|
|
class SystemOverlay final {
|
|
public:
|
|
explicit SystemOverlay(GraphicContext& graphics);
|
|
~SystemOverlay();
|
|
KYTY_CLASS_NO_COPY(SystemOverlay);
|
|
|
|
[[nodiscard]] bool PrepareFrame(vk::Extent2D extent, vk::Format format, uint32_t image_count);
|
|
void Record(vk::CommandBuffer command, vk::ImageView target);
|
|
void ReleaseVulkan();
|
|
|
|
private:
|
|
struct Impl;
|
|
std::unique_ptr<Impl> m_impl;
|
|
};
|
|
|
|
} // namespace Libs::Graphics
|
|
|
|
#endif // EMULATOR_SRC_GRAPHICS_PRESENTATION_SYSTEMOVERLAY_H_
|