Changeset View
Changeset View
Standalone View
Standalone View
plugins/platforms/drm/drm_output.h
Show First 20 Lines • Show All 77 Lines • ▼ Show 20 Line(s) | 48 | public: | |||
---|---|---|---|---|---|
78 | const DrmPlane *primaryPlane() const { | 78 | const DrmPlane *primaryPlane() const { | ||
79 | return m_primaryPlane; | 79 | return m_primaryPlane; | ||
80 | } | 80 | } | ||
81 | 81 | | |||
82 | bool initCursor(const QSize &cursorSize); | 82 | bool initCursor(const QSize &cursorSize); | ||
83 | 83 | | |||
84 | bool supportsTransformations() const; | 84 | bool supportsTransformations() const; | ||
85 | 85 | | |||
86 | Q_SIGNALS: | | |||
87 | void dpmsChanged(); | | |||
88 | | ||||
89 | private: | 86 | private: | ||
90 | friend class DrmBackend; | 87 | friend class DrmBackend; | ||
91 | friend class DrmCrtc; // TODO: For use of setModeLegacy. Remove later when we allow multiple connectors per crtc | 88 | friend class DrmCrtc; // TODO: For use of setModeLegacy. Remove later when we allow multiple connectors per crtc | ||
92 | // and save the connector ids in the DrmCrtc instance. | 89 | // and save the connector ids in the DrmCrtc instance. | ||
93 | DrmOutput(DrmBackend *backend); | 90 | DrmOutput(DrmBackend *backend); | ||
94 | 91 | | |||
95 | bool presentAtomically(DrmBuffer *buffer); | 92 | bool presentAtomically(DrmBuffer *buffer); | ||
96 | 93 | | |||
Show All 9 Lines | |||||
106 | void initDpms(drmModeConnector *connector); | 103 | void initDpms(drmModeConnector *connector); | ||
107 | void initOutputDevice(drmModeConnector *connector); | 104 | void initOutputDevice(drmModeConnector *connector); | ||
108 | 105 | | |||
109 | bool isCurrentMode(const drmModeModeInfo *mode) const; | 106 | bool isCurrentMode(const drmModeModeInfo *mode) const; | ||
110 | void initUuid(); | 107 | void initUuid(); | ||
111 | bool initPrimaryPlane(); | 108 | bool initPrimaryPlane(); | ||
112 | bool initCursorPlane(); | 109 | bool initCursorPlane(); | ||
113 | 110 | | |||
114 | void dpmsOnHandler(); | 111 | void atomicEnable(); | ||
115 | void dpmsOffHandler(); | 112 | void atomicDisable(); | ||
113 | void updateEnablement(bool enable) override; | ||||
114 | | ||||
116 | bool dpmsAtomicOff(); | 115 | bool dpmsAtomicOff(); | ||
116 | bool dpmsLegacyApply(); | ||||
117 | | ||||
118 | void dpmsFinishOn(); | ||||
119 | void dpmsFinishOff(); | ||||
120 | | ||||
117 | bool atomicReqModesetPopulate(drmModeAtomicReq *req, bool enable); | 121 | bool atomicReqModesetPopulate(drmModeAtomicReq *req, bool enable); | ||
118 | void updateDpms(KWayland::Server::OutputInterface::DpmsMode mode) override; | 122 | void updateDpms(KWayland::Server::OutputInterface::DpmsMode mode) override; | ||
119 | void updateMode(int modeIndex) override; | 123 | void updateMode(int modeIndex) override; | ||
120 | void setWaylandMode(); | 124 | void setWaylandMode(); | ||
121 | 125 | | |||
122 | void transform(KWayland::Server::OutputDeviceInterface::Transform transform) override; | 126 | void transform(KWayland::Server::OutputDeviceInterface::Transform transform) override; | ||
123 | void automaticRotation(); | 127 | void automaticRotation(); | ||
124 | 128 | | |||
Show All 12 Lines | |||||
137 | DpmsMode m_dpmsModePending = DpmsMode::On; | 141 | DpmsMode m_dpmsModePending = DpmsMode::On; | ||
138 | QByteArray m_uuid; | 142 | QByteArray m_uuid; | ||
139 | 143 | | |||
140 | uint32_t m_blobId = 0; | 144 | uint32_t m_blobId = 0; | ||
141 | DrmPlane* m_primaryPlane = nullptr; | 145 | DrmPlane* m_primaryPlane = nullptr; | ||
142 | DrmPlane* m_cursorPlane = nullptr; | 146 | DrmPlane* m_cursorPlane = nullptr; | ||
143 | QVector<DrmPlane*> m_nextPlanesFlipList; | 147 | QVector<DrmPlane*> m_nextPlanesFlipList; | ||
144 | bool m_pageFlipPending = false; | 148 | bool m_pageFlipPending = false; | ||
145 | bool m_dpmsAtomicOffPending = false; | 149 | bool m_atomicOffPending = false; | ||
146 | bool m_modesetRequested = true; | 150 | bool m_modesetRequested = true; | ||
147 | 151 | | |||
148 | struct { | 152 | struct { | ||
149 | Qt::ScreenOrientation orientation; | 153 | Qt::ScreenOrientation orientation; | ||
150 | drmModeModeInfo mode; | 154 | drmModeModeInfo mode; | ||
151 | DrmPlane::Transformations planeTransformations; | 155 | DrmPlane::Transformations planeTransformations; | ||
152 | QPoint globalPos; | 156 | QPoint globalPos; | ||
153 | bool valid = false; | 157 | bool valid = false; | ||
Show All 13 Lines |