blob: 14e6b369420c1522e87bbda6ff144e4b02209ce0 (
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
|
#pragma once
#include <vector>
#include "drmobject.h"
namespace kms
{
struct ConnectorPriv;
struct Videomode
{
uint32_t clock;
uint16_t hdisplay, hsync_start, hsync_end, htotal, hskew;
uint16_t vdisplay, vsync_start, vsync_end, vtotal, vscan;
uint32_t vrefresh;
uint32_t flags;
uint32_t type;
char name[32]; // XXX
};
class Connector : public DrmObject
{
public:
Connector(Card& card, uint32_t id, uint32_t idx);
~Connector();
void setup();
void print_short() const;
Videomode get_default_mode() const;
Videomode get_mode(const std::string& mode) const;
Crtc* get_current_crtc() const { return m_current_crtc; }
std::vector<Crtc*> get_possible_crtcs() const;
bool connected() const;
private:
ConnectorPriv* m_priv;
std::string m_fullname;
Crtc* m_current_crtc;
};
}
|