mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-11 04:15:43 +00:00
Bug 1264505 - Remove unused method SharedSurface_EGLImage::AcquireConsumerTexture - r=jgilbert
This commit is contained in:
parent
5dbad5ff3a
commit
84b68e96ff
@ -79,8 +79,6 @@ SharedSurface_EGLImage::SharedSurface_EGLImage(GLContext* gl,
|
||||
, mFormats(formats)
|
||||
, mProdTex(prodTex)
|
||||
, mImage(image)
|
||||
, mCurConsGL(nullptr)
|
||||
, mConsTex(0)
|
||||
, mSync(0)
|
||||
{}
|
||||
|
||||
@ -95,12 +93,6 @@ SharedSurface_EGLImage::~SharedSurface_EGLImage()
|
||||
mSync = 0;
|
||||
}
|
||||
|
||||
if (mConsTex) {
|
||||
MOZ_ASSERT(mGarbageBin);
|
||||
mGarbageBin->Trash(mConsTex);
|
||||
mConsTex = 0;
|
||||
}
|
||||
|
||||
if (!mGL->MakeCurrent())
|
||||
return;
|
||||
|
||||
@ -157,28 +149,6 @@ SharedSurface_EGLImage::Display() const
|
||||
return mEGL->Display();
|
||||
}
|
||||
|
||||
void
|
||||
SharedSurface_EGLImage::AcquireConsumerTexture(GLContext* consGL, GLuint* out_texture, GLuint* out_target)
|
||||
{
|
||||
MutexAutoLock lock(mMutex);
|
||||
MOZ_ASSERT(!mCurConsGL || consGL == mCurConsGL);
|
||||
|
||||
if (!mConsTex) {
|
||||
consGL->fGenTextures(1, &mConsTex);
|
||||
MOZ_ASSERT(mConsTex);
|
||||
|
||||
ScopedBindTexture autoTex(consGL, mConsTex, LOCAL_GL_TEXTURE_EXTERNAL);
|
||||
consGL->fEGLImageTargetTexture2D(LOCAL_GL_TEXTURE_EXTERNAL, mImage);
|
||||
|
||||
mCurConsGL = consGL;
|
||||
mGarbageBin = consGL->TexGarbageBin();
|
||||
}
|
||||
|
||||
MOZ_ASSERT(consGL == mCurConsGL);
|
||||
*out_texture = mConsTex;
|
||||
*out_target = LOCAL_GL_TEXTURE_EXTERNAL;
|
||||
}
|
||||
|
||||
bool
|
||||
SharedSurface_EGLImage::ToSurfaceDescriptor(layers::SurfaceDescriptor* const out_descriptor)
|
||||
{
|
||||
|
@ -43,9 +43,6 @@ protected:
|
||||
public:
|
||||
const EGLImage mImage;
|
||||
protected:
|
||||
GLContext* mCurConsGL;
|
||||
GLuint mConsTex;
|
||||
RefPtr<TextureGarbageBin> mGarbageBin;
|
||||
EGLSync mSync;
|
||||
|
||||
SharedSurface_EGLImage(GLContext* gl,
|
||||
@ -79,8 +76,6 @@ public:
|
||||
|
||||
// Implementation-specific functions below:
|
||||
// Returns texture and target
|
||||
void AcquireConsumerTexture(GLContext* consGL, GLuint* out_texture, GLuint* out_target);
|
||||
|
||||
virtual bool ToSurfaceDescriptor(layers::SurfaceDescriptor* const out_descriptor) override;
|
||||
|
||||
virtual bool ReadbackBySharedHandle(gfx::DataSourceSurface* out_surface) override;
|
||||
|
Loading…
Reference in New Issue
Block a user