зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1734649 - Part 1. Remove checks for WebRender based on RenderThread. r=jgilbert
IsAccelAngleSupported would always indicate ANGLE support on Windows but we have a specific variant of GLLibraryEGL::CreateDisplay for use with ANGLE which bypasses this check for the WebRender compositor. It is otherwise only used for WebGL and non-Windows, so we can skip the assertions here. Differential Revision: https://phabricator.services.mozilla.com/D129895
This commit is contained in:
Родитель
a0dd0c9c53
Коммит
bbbb7c2f0e
|
@ -20,7 +20,6 @@
|
|||
#include "mozilla/ScopeExit.h"
|
||||
#include "mozilla/StaticPtr.h"
|
||||
#include "mozilla/layers/CompositorOptions.h"
|
||||
#include "mozilla/webrender/RenderThread.h"
|
||||
#include "mozilla/widget/CompositorWidget.h"
|
||||
#include "mozilla/widget/WinCompositorWidget.h"
|
||||
|
||||
|
@ -382,7 +381,7 @@ static RefPtr<GLContext> CreateForWidget(const HWND window,
|
|||
LOCAL_WGL_FULL_ACCELERATION_ARB,
|
||||
0};
|
||||
const int* attribs;
|
||||
if (wr::RenderThread::IsInRenderThread()) {
|
||||
if (isWebRender) {
|
||||
attribs = kAttribsForWebRender;
|
||||
} else {
|
||||
attribs = kAttribs;
|
||||
|
@ -414,7 +413,7 @@ static RefPtr<GLContext> CreateForWidget(const HWND window,
|
|||
0};
|
||||
|
||||
const int* attribs;
|
||||
if (wr::RenderThread::IsInRenderThread()) {
|
||||
if (isWebRender) {
|
||||
attribs = kAttribsForWebRender;
|
||||
} else {
|
||||
attribs = kAttribs;
|
||||
|
|
|
@ -18,7 +18,6 @@
|
|||
#include "mozilla/StaticPrefs_gfx.h"
|
||||
#include "mozilla/StaticPrefs_webgl.h"
|
||||
#include "mozilla/Unused.h"
|
||||
#include "mozilla/webrender/RenderThread.h"
|
||||
#include "nsDirectoryServiceDefs.h"
|
||||
#include "nsDirectoryServiceUtils.h"
|
||||
#include "nsPrintfCString.h"
|
||||
|
@ -218,11 +217,6 @@ std::shared_ptr<EglDisplay> GLLibraryEGL::CreateDisplay(
|
|||
}
|
||||
|
||||
static bool IsAccelAngleSupported(nsACString* const out_failureId) {
|
||||
if (wr::RenderThread::IsInRenderThread()) {
|
||||
// We can only enter here with WebRender, so assert that this is a
|
||||
// WebRender-enabled build.
|
||||
return true;
|
||||
}
|
||||
if (!gfx::gfxVars::AllowWebglAccelAngle()) {
|
||||
if (out_failureId->IsEmpty()) {
|
||||
*out_failureId = "FEATURE_FAILURE_ACCL_ANGLE_NOT_OK"_ns;
|
||||
|
@ -273,8 +267,6 @@ AngleErrorReporting gAngleErrorReporter;
|
|||
|
||||
static std::shared_ptr<EglDisplay> GetAndInitDisplayForAccelANGLE(
|
||||
GLLibraryEGL& egl, nsACString* const out_failureId) {
|
||||
MOZ_RELEASE_ASSERT(!wr::RenderThread::IsInRenderThread());
|
||||
|
||||
gfx::FeatureState& d3d11ANGLE =
|
||||
gfx::gfxConfig::GetFeature(gfx::Feature::D3D11_HW_ANGLE);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче