Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(228)

Unified Diff: gpu/gles2_conform_support/egl/display.cc

Issue 1331843005: Implemented new fence syncs which replaces the old sync points. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Reverted mojo readme, changed wait() to take a pointer Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gpu/gles2_conform_support/egl/display.h ('k') | gpu/gpu.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/gles2_conform_support/egl/display.cc
diff --git a/gpu/gles2_conform_support/egl/display.cc b/gpu/gles2_conform_support/egl/display.cc
index 546184d1a7f3a18fbe98c8a8a7d8f5a070edf9f4..3168fa9b5f7273c3d8a6b03859e25f942c851cca 100644
--- a/gpu/gles2_conform_support/egl/display.cc
+++ b/gpu/gles2_conform_support/egl/display.cc
@@ -35,7 +35,8 @@ Display::Display(EGLNativeDisplayType display_id)
#endif
create_offscreen_(false),
create_offscreen_width_(0),
- create_offscreen_height_(0) {
+ create_offscreen_height_(0),
+ next_fence_sync_release_(1) {
}
Display::~Display() {
@@ -352,4 +353,16 @@ uint64_t Display::GetCommandBufferID() const {
return 0;
}
+uint64_t Display::GenerateFenceSyncRelease() {
+ return next_fence_sync_release_++;
+}
+
+bool Display::IsFenceSyncRelease(uint64_t release) {
+ return release > 0 && release < next_fence_sync_release_;
+}
+
+bool Display::IsFenceSyncFlushed(uint64_t release) {
+ return IsFenceSyncRelease(release);
+}
+
} // namespace egl
« no previous file with comments | « gpu/gles2_conform_support/egl/display.h ('k') | gpu/gpu.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698