Hermes 0.7.0
Linux game streaming host
Loading...
Searching...
No Matches
display_device.h
Go to the documentation of this file.
1
5#pragma once
6
7// standard includes
8#include <filesystem>
9#include <memory>
10
11// lib includes
12#include <display_device/types.h>
13
14// forward declarations
15namespace platf {
16 class deinit_t;
17}
18
19namespace config {
20 struct video_t;
21}
22
23namespace rtsp_stream {
24 struct launch_session_t;
25}
26
27namespace display_device {
39 [[nodiscard]] std::unique_ptr<platf::deinit_t> init(const std::filesystem::path &persistence_filepath, const config::video_t &video_config);
40
51 [[nodiscard]] std::string map_output_name(const std::string &output_name);
52
53 [[nodiscard]] std::string
54 map_display_name(const std::string &display_name);
55
70 void configure_display(const config::video_t &video_config, const rtsp_stream::launch_session_t &session);
71
90 void configure_display(const SingleDisplayConfiguration &config);
91
103
124 bool reset_persistence();
125
134 [[nodiscard]] EnumeratedDeviceList enumerate_devices();
135
140
145
164 [[nodiscard]] std::variant<failed_to_parse_tag_t, configuration_disabled_tag_t, SingleDisplayConfiguration> parse_configuration(const config::video_t &video_config, const rtsp_stream::launch_session_t &session);
165} // namespace display_device
std::variant< failed_to_parse_tag_t, configuration_disabled_tag_t, SingleDisplayConfiguration > parse_configuration(const config::video_t &video_config, const rtsp_stream::launch_session_t &session)
Parse the user configuration and the session information.
void revert_configuration()
Revert the display configuration and restore the previous state.
std::unique_ptr< platf::deinit_t > init(const std::filesystem::path &persistence_filepath, const config::video_t &video_config)
Initialize the implementation and perform the initial state recovery (if needed).
void configure_display(const config::video_t &video_config, const rtsp_stream::launch_session_t &session)
Configure the display device based on the user configuration and the session information.
EnumeratedDeviceList enumerate_devices()
Enumerate the available devices.
bool reset_persistence()
Reset the persistence and currently held initial display state.
std::string map_output_name(const std::string &output_name)
Map the output name to a specific display.
A tag structure indicating that configuration is disabled.
A tag structure indicating that configuration parsing has failed.