diff options
author | Luboš Luňák <l.lunak@collabora.com> | 2020-12-04 12:14:47 +0100 |
---|---|---|
committer | Luboš Luňák <l.lunak@collabora.com> | 2020-12-07 20:46:49 +0100 |
commit | db89f53c31af997b9bf422b0e784afba8d62a42e (patch) | |
tree | da11fedb71f01b6d21a32f95c0a9ccecb43fc265 /vcl/source/gdi | |
parent | 6265cfca9d775198e81166b914f5dcaea58802db (diff) |
remove OpenGL VCL backend code
It is by now practically unmaintained, even bugreports in bugzilla
have been already closed for it. AFAICT this used to be really
used only on Windows, where it's no longer the default.
There's still some OpenGL code left, because there are still two
other places that use OpenGL. One is OpenGL slideshows, which
reuse some of the base OpenGL code (and I've checked they
still work even after this removal). Second one is OpenGL canvas,
which it seems has never been finished or enabled (or so it
most probably should be dumped too).
Change-Id: I7ea5aef77ec252eb8e712d167db591209be84a13
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107290
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
Diffstat (limited to 'vcl/source/gdi')
-rw-r--r-- | vcl/source/gdi/bitmap3.cxx | 4 | ||||
-rw-r--r-- | vcl/source/gdi/salgdilayout.cxx | 43 |
2 files changed, 0 insertions, 47 deletions
diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx index 3b0b1cd76bfb..28e599f3cbed 100644 --- a/vcl/source/gdi/bitmap3.cxx +++ b/vcl/source/gdi/bitmap3.cxx @@ -784,10 +784,6 @@ bool Bitmap::HasFastScale() if( SkiaHelper::isVCLSkiaEnabled() && SkiaHelper::renderMethodToUse() != SkiaHelper::RenderRaster) return true; #endif -#if HAVE_FEATURE_OPENGL - if( OpenGLHelper::isVCLOpenGLEnabled()) - return true; -#endif return false; } diff --git a/vcl/source/gdi/salgdilayout.cxx b/vcl/source/gdi/salgdilayout.cxx index eab208eb8689..e5fe48e851ab 100644 --- a/vcl/source/gdi/salgdilayout.cxx +++ b/vcl/source/gdi/salgdilayout.cxx @@ -20,14 +20,6 @@ #include <memory> #include <config_features.h> #include <sal/log.hxx> -#if HAVE_FEATURE_OPENGL -#include <opengl/gdiimpl.hxx> -#include <opengl/zone.hxx> -#include <desktop/exithelper.h> -#ifdef _WIN32 -#include <svsys.h> -#endif -#endif #include <PhysicalFontFace.hxx> #include <fontsubset.hxx> #include <salgdi.hxx> @@ -90,41 +82,6 @@ SalGraphics::~SalGraphics() COVERITY_NOEXCEPT_FALSE // can't call ReleaseFonts here, as the destructor just calls this classes SetFont (pure virtual)! } -#if HAVE_FEATURE_OPENGL - -namespace -{ - void disableOpenGLAndTerminateForRestart() - { - OpenGLZone::hardDisable(); -#ifdef _WIN32 - TerminateProcess(GetCurrentProcess(), EXITHELPER_NORMAL_RESTART); -#endif - } -} - -rtl::Reference<OpenGLContext> SalGraphics::GetOpenGLContext() const -{ - OpenGLSalGraphicsImpl *pImpl = dynamic_cast<OpenGLSalGraphicsImpl*>(GetImpl()); - if (pImpl) - { - // If we notice that OpenGL is broken the first time being called, it is not too late to call - // disableOpenGLAndTerminateForRestart(). The first time this will be called is from displaying - // the splash screen, so if OpenGL is broken, it is "early enough" for us to be able to disable - // OpenGL and terminate bluntly with EXITHELPER_NORMAL_RESTART, thus causing the wrapper process - // to restart us, then without using OpenGL. - static bool bFirstCall = true; - rtl::Reference<OpenGLContext> xRet(pImpl->GetOpenGLContext()); - if (!xRet.is() && bFirstCall) - disableOpenGLAndTerminateForRestart(); - bFirstCall = false; - return xRet; - } - return nullptr; -} - -#endif - bool SalGraphics::drawTransformedBitmap( const basegfx::B2DPoint& /* rNull */, const basegfx::B2DPoint& /* rX */, |