mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 933530 - Remove mDataIsCurrent from SharedSurfaceGL. r=jgilbert
This commit is contained in:
parent
0af6720261
commit
5e29ba50b8
@ -70,7 +70,6 @@ SharedSurface_Basic::SharedSurface_Basic(GLContext* gl,
|
||||
hasAlpha)
|
||||
, mTex(tex)
|
||||
, mFB(0)
|
||||
, mIsDataCurrent(false)
|
||||
{
|
||||
mGL->MakeCurrent();
|
||||
mGL->fGenFramebuffers(1, &mFB);
|
||||
@ -116,50 +115,40 @@ SharedSurface_Basic::Fence()
|
||||
mGL->MakeCurrent();
|
||||
ScopedBindFramebuffer autoFB(mGL, mFB);
|
||||
ReadPixelsIntoDataSurface(mGL, mData);
|
||||
mIsDataCurrent = true;
|
||||
}
|
||||
|
||||
bool
|
||||
SharedSurface_Basic::WaitSync()
|
||||
{
|
||||
MOZ_ASSERT(mIsDataCurrent);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool
|
||||
SharedSurface_Basic::PollSync()
|
||||
{
|
||||
MOZ_ASSERT(mIsDataCurrent);
|
||||
return true;
|
||||
}
|
||||
|
||||
void
|
||||
SharedSurface_Basic::Fence_ContentThread_Impl()
|
||||
{
|
||||
mIsDataCurrent = false;
|
||||
}
|
||||
|
||||
bool
|
||||
SharedSurface_Basic::WaitSync_ContentThread_Impl()
|
||||
{
|
||||
if (!mIsDataCurrent) {
|
||||
mGL->MakeCurrent();
|
||||
ScopedBindFramebuffer autoFB(mGL, mFB);
|
||||
ReadPixelsIntoDataSurface(mGL, mData);
|
||||
mIsDataCurrent = true;
|
||||
}
|
||||
mGL->MakeCurrent();
|
||||
ScopedBindFramebuffer autoFB(mGL, mFB);
|
||||
ReadPixelsIntoDataSurface(mGL, mData);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool
|
||||
SharedSurface_Basic::PollSync_ContentThread_Impl()
|
||||
{
|
||||
if (!mIsDataCurrent) {
|
||||
mGL->MakeCurrent();
|
||||
ScopedBindFramebuffer autoFB(mGL, mFB);
|
||||
ReadPixelsIntoDataSurface(mGL, mData);
|
||||
mIsDataCurrent = true;
|
||||
}
|
||||
mGL->MakeCurrent();
|
||||
ScopedBindFramebuffer autoFB(mGL, mFB);
|
||||
ReadPixelsIntoDataSurface(mGL, mData);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -48,7 +48,6 @@ protected:
|
||||
const GLuint mTex;
|
||||
GLuint mFB;
|
||||
RefPtr<gfx::DataSourceSurface> mData;
|
||||
bool mIsDataCurrent;
|
||||
|
||||
SharedSurface_Basic(GLContext* gl,
|
||||
const gfx::IntSize& size,
|
||||
|
Loading…
Reference in New Issue
Block a user