Sunshine
v2025.118.151840
Self-hosted game stream host for Moonlight.
undo_data.h
Go to the documentation of this file.
1
5
#pragma once
6
7
// standard library headers
8
#include <cstdint>
9
#include <optional>
10
#include <string>
11
#include <vector>
12
13
namespace
nvprefs {
14
15
class
undo_data_t
{
16
public
:
17
struct
data_t
{
18
struct
opengl_swapchain_t
{
19
uint32_t our_value;
20
std::optional<uint32_t> undo_value;
21
};
22
23
std::optional<opengl_swapchain_t> opengl_swapchain;
24
};
25
26
void
27
set_opengl_swapchain(uint32_t our_value, std::optional<uint32_t> undo_value);
28
29
std::optional<data_t::opengl_swapchain_t>
30
get_opengl_swapchain()
const
;
31
32
std::string
33
write()
const
;
34
35
void
36
read(
const
std::vector<char> &buffer);
37
38
void
39
merge(
const
undo_data_t
&newer_data);
40
41
private
:
42
data_t
data;
43
};
44
45
}
// namespace nvprefs
nvprefs::undo_data_t
Definition
undo_data.h:15
nvprefs::undo_data_t::data_t::opengl_swapchain_t
Definition
undo_data.h:18
nvprefs::undo_data_t::data_t
Definition
undo_data.h:17
src
platform
windows
nvprefs
undo_data.h
Generated by
1.10.0