blob: b56300018d92b743a251fa6cb7806b4ec360e276 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
#pragma once
#include <string>
#include <vector>
#include <mglpp/system/vec.hpp>
namespace gsr {
struct SupportedVideoCodecs {
bool h264 = false;
bool hevc = false;
bool av1 = false;
bool vp8 = false;
bool vp9 = false;
};
struct GsrMonitor {
std::string name;
mgl::vec2i size;
};
struct SupportedCaptureOptions {
bool window = false;
bool focused = false;
bool screen = false;
bool portal = false;
std::vector<GsrMonitor> monitors;
};
enum class DisplayServer {
UNKNOWN,
X11,
WAYLAND
};
struct SystemInfo {
DisplayServer display_server = DisplayServer::UNKNOWN;
};
enum class GpuVendor {
UNKNOWN,
AMD,
INTEL,
NVIDIA
};
struct GpuInfo {
GpuVendor vendor = GpuVendor::UNKNOWN;
};
struct GsrInfo {
SystemInfo system_info;
GpuInfo gpu_info;
SupportedVideoCodecs supported_video_codecs;
SupportedCaptureOptions supported_capture_options;
};
enum class GsrInfoExitStatus {
OK,
FAILED_TO_RUN_COMMAND,
OPENGL_FAILED,
NO_DRM_CARD
};
struct AudioDevice {
std::string name;
std::string description;
};
GsrInfoExitStatus get_gpu_screen_recorder_info(GsrInfo *gsr_info);
std::vector<AudioDevice> get_audio_devices();
}
|