34 static QMatrix4x4
colorMatrix(qreal contrast, qreal intensity, qreal saturation);
45 bool eventFilter(QObject *watched, QEvent *event)
override;
59 void doContrast(
const RenderTarget &renderTarget,
const RenderViewport &viewport,
EffectWindow *w,
const QRegion &shape,
const QRect &screen,
const float opacity,
const QMatrix4x4 &screenProjection);
60 void uploadRegion(std::span<QVector2D> map,
const QRegion ®ion, qreal scale);
61 Q_REQUIRED_RESULT
bool uploadGeometry(
GLVertexBuffer *vbo,
const QRegion ®ion, qreal scale);
64 std::unique_ptr<ContrastShader> m_shader;
65 long m_net_wm_contrast_region = 0;
66 QHash<const EffectWindow *, QMetaObject::Connection> m_contrastChangedConnections;
69 QMatrix4x4 colorMatrix;
70 QRegion contrastRegion;
71 std::unique_ptr<GLTexture> texture;
72 std::unique_ptr<GLFramebuffer> fbo;
74 std::unordered_map<const EffectWindow *, Data> m_windowData;
75 static ContrastManagerInterface *s_contrastManager;
76 static QTimer *s_contrastManagerRemoveTimer;
void drawWindow(const RenderTarget &renderTarget, const RenderViewport &viewport, EffectWindow *w, int mask, const QRegion ®ion, WindowPaintData &data) override