summaryrefslogtreecommitdiffstats
path: root/src/core/ozone
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2021-01-22 10:55:57 +0100
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2021-01-25 15:41:53 +0100
commitcde72003881c6b5680ac8ac0fe6d6971bb43e0d5 (patch)
treefcb50002765c1cb179dd6f62054380c3fed85e80 /src/core/ozone
parent3fb215dab139fd7b61473ce3fe1058b87a6b4fe3 (diff)
parent75d061bbc68875c08b3dc243e464e32a80da71df (diff)
Merge remote-tracking branch 'origin/5.15' into dev
Including update to 87-based Change-Id: I36b6054e00de97ab055d0bc800cff08d0408fac6
Diffstat (limited to 'src/core/ozone')
-rw-r--r--src/core/ozone/gl_share_context_qt.cpp2
-rw-r--r--src/core/ozone/gl_share_context_qt.h4
-rw-r--r--src/core/ozone/gl_surface_egl_qt.cpp19
-rw-r--r--src/core/ozone/gl_surface_glx_qt.cpp14
-rw-r--r--src/core/ozone/gl_surface_glx_qt.h4
-rw-r--r--src/core/ozone/gl_surface_qt.cpp8
-rw-r--r--src/core/ozone/ozone_platform_qt.cpp10
7 files changed, 41 insertions, 20 deletions
diff --git a/src/core/ozone/gl_share_context_qt.cpp b/src/core/ozone/gl_share_context_qt.cpp
index c2cfecb8b..a17321455 100644
--- a/src/core/ozone/gl_share_context_qt.cpp
+++ b/src/core/ozone/gl_share_context_qt.cpp
@@ -81,7 +81,7 @@ QtShareGLContext::QtShareGLContext(QOpenGLContext *qtContext)
#endif // QT_CONFIG(opengl)
}
-unsigned int QtShareGLContext::CheckStickyGraphicsResetStatus()
+unsigned int QtShareGLContext::CheckStickyGraphicsResetStatusImpl()
{
#if QT_CONFIG(opengl)
if (QOpenGLContext *context = QOpenGLContext::globalShareContext()) {
diff --git a/src/core/ozone/gl_share_context_qt.h b/src/core/ozone/gl_share_context_qt.h
index 26e884e10..b07f5123e 100644
--- a/src/core/ozone/gl_share_context_qt.h
+++ b/src/core/ozone/gl_share_context_qt.h
@@ -55,14 +55,14 @@ class QtShareGLContext : public gl::GLContext
public:
QtShareGLContext(QOpenGLContext *qtContext);
void *GetHandle() override { return m_handle; }
- unsigned int CheckStickyGraphicsResetStatus() override;
+ unsigned int CheckStickyGraphicsResetStatusImpl() override;
// We don't care about the rest, this context shouldn't be used except for its handle.
bool Initialize(gl::GLSurface *, const gl::GLContextAttribs &) override
{
Q_UNREACHABLE();
return false;
}
- bool MakeCurrent(gl::GLSurface *) override
+ bool MakeCurrentImpl(gl::GLSurface *) override
{
Q_UNREACHABLE();
return false;
diff --git a/src/core/ozone/gl_surface_egl_qt.cpp b/src/core/ozone/gl_surface_egl_qt.cpp
index 8e8e66f63..91402abfe 100644
--- a/src/core/ozone/gl_surface_egl_qt.cpp
+++ b/src/core/ozone/gl_surface_egl_qt.cpp
@@ -44,7 +44,7 @@
#include "gl_context_qt.h"
#include "ozone/gl_surface_egl_qt.h"
-#if !defined(OS_MACOSX)
+#if !defined(OS_MAC)
#include "ui/gl/egl_util.h"
#include "ui/gl/gl_surface_egl.h"
#include "ui/gl/init/gl_factory.h"
@@ -181,6 +181,21 @@ bool GLSurfaceEGL::IsANGLEFeatureControlSupported()
return false;
}
+bool GLSurfaceEGL::IsANGLEPowerPreferenceSupported()
+{
+ return false;
+}
+
+bool GLSurfaceEGL::IsDisplaySemaphoreShareGroupSupported()
+{
+ return false;
+}
+
+bool GLSurfaceEGL::IsRobustnessVideoMemoryPurgeSupported()
+{
+ return false;
+}
+
void GLSurfaceEGL::ShutdownOneOff()
{
}
@@ -340,4 +355,4 @@ std::string DriverEGL::GetPlatformExtensions()
return "";
}
} // namespace gl
-#endif // !defined(OS_MACOSX)
+#endif // !defined(OS_MAC)
diff --git a/src/core/ozone/gl_surface_glx_qt.cpp b/src/core/ozone/gl_surface_glx_qt.cpp
index e150c940a..188a92729 100644
--- a/src/core/ozone/gl_surface_glx_qt.cpp
+++ b/src/core/ozone/gl_surface_glx_qt.cpp
@@ -45,8 +45,7 @@
#include "ozone/gl_surface_glx_qt.h"
#include "ui/gl/gl_bindings.h"
#include "ui/gl/gl_surface_glx.h"
-#include <GL/glx.h>
-#include <GL/glxext.h>
+#include "ui/gfx/x/x11_types.h"
namespace gl {
@@ -106,6 +105,11 @@ bool GLSurfaceGLX::IsTextureFromPixmapSupported()
return ExtensionsContain(GLSurfaceQt::g_extensions, "GLX_EXT_texture_from_pixmap");
}
+bool GLSurfaceGLX::IsRobustnessVideoMemoryPurgeSupported()
+{
+ return false;
+}
+
const char* GLSurfaceGLX::GetGLXExtensions()
{
return GLSurfaceQt::g_extensions;
@@ -171,9 +175,9 @@ bool GLSurfaceGLXQt::Initialize(GLSurfaceFormat format)
const int pbuffer_attributes[] = {
GLX_PBUFFER_WIDTH, m_size.width(),
GLX_PBUFFER_HEIGHT, m_size.height(),
- GLX_LARGEST_PBUFFER, x11::False,
- GLX_PRESERVED_CONTENTS, x11::False,
- x11::None // MEMO doc: ...must be terminated with None or NULL
+ GLX_LARGEST_PBUFFER, GL_FALSE,
+ GLX_PRESERVED_CONTENTS, GL_FALSE,
+ GL_NONE // MEMO doc: ...must be terminated with None or NULL
};
m_surfaceBuffer = glXCreatePbuffer(display, static_cast<GLXFBConfig>(g_config), pbuffer_attributes);
diff --git a/src/core/ozone/gl_surface_glx_qt.h b/src/core/ozone/gl_surface_glx_qt.h
index 3a465f448..e894423b7 100644
--- a/src/core/ozone/gl_surface_glx_qt.h
+++ b/src/core/ozone/gl_surface_glx_qt.h
@@ -42,9 +42,7 @@
#include "gl_surface_qt.h"
-extern "C" {
-#include <X11/Xlib.h>
-}
+#include "ui/gfx/x/x11_types.h"
namespace gl {
diff --git a/src/core/ozone/gl_surface_qt.cpp b/src/core/ozone/gl_surface_qt.cpp
index 90f486532..2c464c11c 100644
--- a/src/core/ozone/gl_surface_qt.cpp
+++ b/src/core/ozone/gl_surface_qt.cpp
@@ -43,7 +43,7 @@
#include "gl_surface_qt.h"
-#if !defined(OS_MACOSX)
+#if !defined(OS_MAC)
#include <QGuiApplication>
#include "gl_context_qt.h"
@@ -254,6 +254,10 @@ UINT DirectCompositionSurfaceWin::GetOverlaySupportFlags(DXGI_FORMAT format)
Q_UNUSED(format);
return 0;
}
+
+void DirectCompositionSurfaceWin::DisableDecodeSwapChain()
+{
+}
} // namespace gl
#endif
-#endif // !defined(OS_MACOSX)
+#endif // !defined(OS_MAC)
diff --git a/src/core/ozone/ozone_platform_qt.cpp b/src/core/ozone/ozone_platform_qt.cpp
index 3674ccfe6..9db5b9986 100644
--- a/src/core/ozone/ozone_platform_qt.cpp
+++ b/src/core/ozone/ozone_platform_qt.cpp
@@ -40,11 +40,11 @@
#include "ozone_platform_qt.h"
#if defined(USE_OZONE)
+#include "ui/base/cursor/ozone/bitmap_cursor_factory_ozone.h"
#include "ui/base/ime/input_method.h"
#include "ui/display/types/native_display_delegate.h"
#include "ui/ozone/common/stub_client_native_pixmap_factory.h"
#include "ui/ozone/common/stub_overlay_manager.h"
-#include "ui/ozone/public/cursor_factory_ozone.h"
#include "ui/ozone/public/gpu_platform_support_host.h"
#include "ui/ozone/public/input_controller.h"
#include "ui/ozone/public/ozone_platform.h"
@@ -66,7 +66,7 @@ public:
~OzonePlatformQt() override;
ui::SurfaceFactoryOzone* GetSurfaceFactoryOzone() override;
- ui::CursorFactoryOzone* GetCursorFactoryOzone() override;
+ ui::CursorFactory* GetCursorFactory() override;
GpuPlatformSupportHost* GetGpuPlatformSupportHost() override;
std::unique_ptr<PlatformWindow> CreatePlatformWindow(PlatformWindowDelegate* delegate, PlatformWindowInitProperties properties) override;
std::unique_ptr<display::NativeDisplayDelegate> CreateNativeDisplayDelegate() override;
@@ -80,7 +80,7 @@ private:
void InitializeGPU(const ui::OzonePlatform::InitParams &) override;
std::unique_ptr<QtWebEngineCore::SurfaceFactoryQt> surface_factory_ozone_;
- std::unique_ptr<CursorFactoryOzone> cursor_factory_ozone_;
+ std::unique_ptr<CursorFactory> cursor_factory_ozone_;
std::unique_ptr<GpuPlatformSupportHost> gpu_platform_support_host_;
std::unique_ptr<InputController> input_controller_;
@@ -99,7 +99,7 @@ ui::SurfaceFactoryOzone* OzonePlatformQt::GetSurfaceFactoryOzone()
return surface_factory_ozone_.get();
}
-ui::CursorFactoryOzone* OzonePlatformQt::GetCursorFactoryOzone()
+ui::CursorFactory* OzonePlatformQt::GetCursorFactory()
{
return cursor_factory_ozone_.get();
}
@@ -138,7 +138,7 @@ std::unique_ptr<display::NativeDisplayDelegate> OzonePlatformQt::CreateNativeDis
void OzonePlatformQt::InitializeUI(const ui::OzonePlatform::InitParams &)
{
overlay_manager_.reset(new StubOverlayManager());
- cursor_factory_ozone_.reset(new CursorFactoryOzone());
+ cursor_factory_ozone_.reset(new BitmapCursorFactoryOzone());
gpu_platform_support_host_.reset(ui::CreateStubGpuPlatformSupportHost());
input_controller_ = CreateStubInputController();
}