зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1118100. Remove unused SharedSurfaceIO code. r=jgilbert
--HG-- extra : rebase_source : 9bdd90db5755903fcffdce1f7b95687844c6dfad
This commit is contained in:
Родитель
6b8a74ae55
Коммит
a0b39046de
|
@ -102,8 +102,6 @@ SharedSurface_IOSurface::SharedSurface_IOSurface(const RefPtr<MacIOSurface>& ioS
|
|||
size,
|
||||
hasAlpha)
|
||||
, mIOSurf(ioSurf)
|
||||
, mCurConsGL(nullptr)
|
||||
, mConsTex(0)
|
||||
{
|
||||
gl->MakeCurrent();
|
||||
mProdTex = 0;
|
||||
|
@ -111,31 +109,12 @@ SharedSurface_IOSurface::SharedSurface_IOSurface(const RefPtr<MacIOSurface>& ioS
|
|||
BackTextureWithIOSurf(gl, mProdTex, mIOSurf);
|
||||
}
|
||||
|
||||
GLuint
|
||||
SharedSurface_IOSurface::ConsTexture(GLContext* consGL)
|
||||
{
|
||||
if (!mCurConsGL) {
|
||||
mCurConsGL = consGL;
|
||||
}
|
||||
MOZ_ASSERT(consGL == mCurConsGL);
|
||||
|
||||
if (!mConsTex) {
|
||||
consGL->MakeCurrent();
|
||||
mConsTex = 0;
|
||||
consGL->fGenTextures(1, &mConsTex);
|
||||
BackTextureWithIOSurf(consGL, mConsTex, mIOSurf);
|
||||
}
|
||||
|
||||
return mConsTex;
|
||||
}
|
||||
|
||||
SharedSurface_IOSurface::~SharedSurface_IOSurface()
|
||||
{
|
||||
if (mProdTex) {
|
||||
DebugOnly<bool> success = mGL->MakeCurrent();
|
||||
MOZ_ASSERT(success);
|
||||
mGL->fDeleteTextures(1, &mProdTex);
|
||||
mGL->fDeleteTextures(1, &mConsTex); // This will work if we're shared.
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -46,12 +46,6 @@ public:
|
|||
return static_cast<SharedSurface_IOSurface*>(surf);
|
||||
}
|
||||
|
||||
GLuint ConsTexture(GLContext* consGL);
|
||||
|
||||
GLenum ConsTextureTarget() const {
|
||||
return LOCAL_GL_TEXTURE_RECTANGLE_ARB;
|
||||
}
|
||||
|
||||
MacIOSurface* GetIOSurface() const {
|
||||
return mIOSurf;
|
||||
}
|
||||
|
@ -67,8 +61,6 @@ private:
|
|||
|
||||
RefPtr<MacIOSurface> mIOSurf;
|
||||
GLuint mProdTex;
|
||||
const GLContext* mCurConsGL;
|
||||
GLuint mConsTex;
|
||||
};
|
||||
|
||||
class SurfaceFactory_IOSurface : public SurfaceFactory
|
||||
|
|
Загрузка…
Ссылка в новой задаче