Bug 1265824 - Remove the unsed member in GLTextureSource r=mattwoodrow

The "mExternallyOwned" is used for gralloc buffer. We don't use the gralloc buffer now.

MozReview-Commit-ID: 7Gurpa3kdp0

--HG--
extra : rebase_source : 5c0bf4facba5ed2cc8772df78bb702965e77a4ab
This commit is contained in:
Doug Thayer 2018-05-02 18:19:54 -07:00
parent a24d524daf
commit ad1ca0fa4e
2 changed files with 5 additions and 16 deletions

View File

@ -242,14 +242,12 @@ GLTextureSource::GLTextureSource(TextureSourceProvider* aProvider,
GLuint aTextureHandle,
GLenum aTarget,
gfx::IntSize aSize,
gfx::SurfaceFormat aFormat,
bool aExternallyOwned)
gfx::SurfaceFormat aFormat)
: mGL(aProvider->GetGLContext())
, mTextureHandle(aTextureHandle)
, mTextureTarget(aTarget)
, mSize(aSize)
, mFormat(aFormat)
, mExternallyOwned(aExternallyOwned)
{
MOZ_COUNT_CTOR(GLTextureSource);
}
@ -257,17 +255,13 @@ GLTextureSource::GLTextureSource(TextureSourceProvider* aProvider,
GLTextureSource::~GLTextureSource()
{
MOZ_COUNT_DTOR(GLTextureSource);
if (!mExternallyOwned) {
DeleteTextureHandle();
}
DeleteTextureHandle();
}
void
GLTextureSource::DeallocateDeviceData()
{
if (!mExternallyOwned) {
DeleteTextureHandle();
}
DeleteTextureHandle();
}
void
@ -764,8 +758,7 @@ GLTextureHost::Lock()
mTexture,
mTarget,
mSize,
format,
false /* owned by the client */);
format);
}
return true;

View File

@ -232,8 +232,7 @@ public:
GLuint aTextureHandle,
GLenum aTarget,
gfx::IntSize aSize,
gfx::SurfaceFormat aFormat,
bool aExternallyOwned = false);
gfx::SurfaceFormat aFormat);
~GLTextureSource();
@ -279,9 +278,6 @@ protected:
GLenum mTextureTarget;
gfx::IntSize mSize;
gfx::SurfaceFormat mFormat;
// If the texture is externally owned, the gl handle will not be deleted
// in the destructor.
bool mExternallyOwned;
};
class GLTextureHost : public TextureHost