Changeset View
Changeset View
Standalone View
Standalone View
platformsupport/scenes/opengl/abstract_egl_backend.cpp
Show All 18 Lines | |||||
19 | *********************************************************************/ | 19 | *********************************************************************/ | ||
20 | #include "abstract_egl_backend.h" | 20 | #include "abstract_egl_backend.h" | ||
21 | #include "texture.h" | 21 | #include "texture.h" | ||
22 | #include "composite.h" | 22 | #include "composite.h" | ||
23 | #include "egl_context_attribute_builder.h" | 23 | #include "egl_context_attribute_builder.h" | ||
24 | #include "options.h" | 24 | #include "options.h" | ||
25 | #include "platform.h" | 25 | #include "platform.h" | ||
26 | #include "scene.h" | 26 | #include "scene.h" | ||
27 | #include "abstract_output.h" | ||||
zzag: Please move it before "composite.h" | |||||
27 | #include "wayland_server.h" | 28 | #include "wayland_server.h" | ||
28 | #include <KWayland/Server/buffer_interface.h> | 29 | #include <KWayland/Server/buffer_interface.h> | ||
29 | #include <KWayland/Server/display.h> | 30 | #include <KWayland/Server/display.h> | ||
30 | #include <KWayland/Server/surface_interface.h> | 31 | #include <KWayland/Server/surface_interface.h> | ||
31 | // kwin libs | 32 | // kwin libs | ||
zzag: This is a kwin core include, thus it should go above. | |||||
32 | #include <logging.h> | 33 | #include <logging.h> | ||
33 | #include <kwinglplatform.h> | 34 | #include <kwinglplatform.h> | ||
34 | #include <kwinglutils.h> | 35 | #include <kwinglutils.h> | ||
35 | // Qt | 36 | // Qt | ||
36 | #include <QOpenGLContext> | 37 | #include <QOpenGLContext> | ||
37 | #include <QOpenGLFramebufferObject> | 38 | #include <QOpenGLFramebufferObject> | ||
38 | 39 | | |||
39 | #include <memory> | 40 | #include <memory> | ||
▲ Show 20 Lines • Show All 501 Lines • ▼ Show 20 Line(s) | 537 | { | |||
541 | m_size = fbo->size(); | 542 | m_size = fbo->size(); | ||
542 | q->setWrapMode(GL_CLAMP_TO_EDGE); | 543 | q->setWrapMode(GL_CLAMP_TO_EDGE); | ||
543 | q->setFilter(GL_LINEAR); | 544 | q->setFilter(GL_LINEAR); | ||
544 | q->setYInverted(false); | 545 | q->setYInverted(false); | ||
545 | updateMatrix(); | 546 | updateMatrix(); | ||
546 | return true; | 547 | return true; | ||
547 | } | 548 | } | ||
548 | 549 | | |||
550 | | ||||
551 | QRect AbstractEglBackend::orientateRect(AbstractOutput *output, const QRect &r) | ||||
552 | { | ||||
553 | if (output->softwareRotationAngle() != 0) { | ||||
554 | QTransform m; | ||||
555 | m.rotate(-output->softwareRotationAngle(), Qt::ZAxis); | ||||
556 | return QRect(m.map(r.topLeft()), r.size()); | ||||
557 | } | ||||
558 | return r; | ||||
559 | } | ||||
560 | | ||||
549 | } | 561 | } | ||
550 | 562 | |
Please move it before "composite.h"