Revert "[SurfaceFlinger] Add GPU protected content support."
This reverts commit dc979249d3bdd678e63358aacb27aa9a5cd02f51.
Reason for revert: broke emulator b/121038163
Change-Id: I3c93fe7d91431a3000094915c909811d1796305d
diff --git a/libs/renderengine/gl/GLESRenderEngine.h b/libs/renderengine/gl/GLESRenderEngine.h
index 07e5585..21d5b81 100644
--- a/libs/renderengine/gl/GLESRenderEngine.h
+++ b/libs/renderengine/gl/GLESRenderEngine.h
@@ -45,8 +45,7 @@
static EGLConfig chooseEglConfig(EGLDisplay display, int format, bool logConfig);
GLESRenderEngine(uint32_t featureFlags, // See RenderEngine::FeatureFlag
- EGLDisplay display, EGLConfig config, EGLContext ctxt, EGLSurface dummy,
- EGLContext protectedContext, EGLSurface protectedDummy);
+ EGLDisplay display, EGLConfig config, EGLContext ctxt, EGLSurface dummy);
~GLESRenderEngine() override;
std::unique_ptr<Framebuffer> createFramebuffer() override;
@@ -69,9 +68,6 @@
void unbindFrameBuffer(Framebuffer* framebuffer) override;
void checkErrors() const override;
- bool isProtected() const override { return mInProtectedContext; }
- bool supportsProtectedContent() const override;
- bool useProtectedContext(bool useProtectedContext) override;
status_t drawLayers(const DisplaySettings& settings, const std::vector<LayerSettings>& layers,
ANativeWindowBuffer* const buffer,
base::unique_fd* displayFence) const override;
@@ -116,22 +112,20 @@
static GlesVersion parseGlesVersion(const char* str);
static EGLContext createEglContext(EGLDisplay display, EGLConfig config,
- EGLContext shareContext, bool useContextPriority,
- Protection protection);
+ EGLContext shareContext, bool useContextPriority);
static EGLSurface createDummyEglPbufferSurface(EGLDisplay display, EGLConfig config,
- int hwcFormat, Protection protection);
+ int hwcFormat);
// A data space is considered HDR data space if it has BT2020 color space
// with PQ or HLG transfer function.
bool isHdrDataSpace(const ui::Dataspace dataSpace) const;
bool needsXYZTransformMatrix() const;
+ void setEGLHandles(EGLDisplay display, EGLConfig config, EGLContext ctxt, EGLSurface dummy);
EGLDisplay mEGLDisplay;
EGLConfig mEGLConfig;
EGLContext mEGLContext;
EGLSurface mDummySurface;
- EGLContext mProtectedEGLContext;
- EGLSurface mProtectedDummySurface;
GLuint mProtectedTexName;
GLint mMaxViewportDims[2];
GLint mMaxTextureSize;
@@ -152,7 +146,6 @@
mat4 mBt2020ToSrgb;
mat4 mBt2020ToDisplayP3;
- bool mInProtectedContext = false;
int32_t mFboHeight = 0;
// Current dataspace of layer being rendered