Revert GLEscrow changes

This commit is contained in:
Anthony J. Thibault 2016-03-23 17:11:16 -07:00
parent 0d37515784
commit 8bb387dc74

View file

@ -71,16 +71,11 @@ public:
}
bool signaled() const {
#if THREADED_PRESENT
auto result = glClientWaitSync(_sync, 0, 0);
if (GL_TIMEOUT_EXPIRED != result && GL_WAIT_FAILED != result) {
return true;
}
return false;
#else
glWaitSync(_sync, 0, GL_TIMEOUT_IGNORED);
return true;
#endif
}
};
@ -208,15 +203,13 @@ public:
// Also releases any previous texture held by the caller
bool fetchSignaledAndRelease(T& value) {
T originalValue = value;
bool fetched = false;
while (fetchSignaled(value)) {
fetched = true;
if (fetchSignaled(value)) {
if (originalValue != invalid()) {
release(originalValue);
}
originalValue = value;
return true;
}
return fetched;
return false;
}
bool fetchAndReleaseWithFence(T& value, GLsync& sync) {