aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/gpu/TestContext.h
diff options
context:
space:
mode:
authorGravatar csmartdalton <csmartdalton@google.com>2016-10-04 11:08:45 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-10-04 11:08:45 -0700
commit421a3c1cc1b227084c7c84618d0b6a6804faabef (patch)
tree121df15df779adc93866c323571c3a02ee349429 /tools/gpu/TestContext.h
parentd36baa7a4a5ae3cc94cc4a45379f55658f80c0a6 (diff)
Move GPU fences into sk_gpu_test
Diffstat (limited to 'tools/gpu/TestContext.h')
-rw-r--r--tools/gpu/TestContext.h12
1 files changed, 4 insertions, 8 deletions
diff --git a/tools/gpu/TestContext.h b/tools/gpu/TestContext.h
index ffa8cae8f9..d01cb02af2 100644
--- a/tools/gpu/TestContext.h
+++ b/tools/gpu/TestContext.h
@@ -9,8 +9,8 @@
#ifndef TestContext_DEFINED
#define TestContext_DEFINED
+#include "FenceSync.h"
#include "GrTypes.h"
-#include "../private/SkGpuFenceSync.h"
#include "../private/SkTemplates.h"
namespace sk_gpu_test {
@@ -25,6 +25,7 @@ public:
virtual bool isValid() const = 0;
bool fenceSyncSupport() const { return fFenceSync != nullptr; }
+ FenceSync* fenceSync() { SkASSERT(fFenceSync); return fFenceSync; }
bool getMaxGpuFrameLag(int *maxFrameLag) const {
if (!fFenceSync) {
@@ -73,13 +74,8 @@ public:
/** Wait until all GPU work is finished. */
virtual void finish() = 0;
- /**
- * returns the fencesync object owned by this GLTestContext
- */
- SkGpuFenceSync *fenceSync() { return fFenceSync; }
-
protected:
- SkGpuFenceSync* fFenceSync;
+ FenceSync* fFenceSync;
TestContext();
@@ -94,7 +90,7 @@ private:
kMaxFrameLag = 3
};
- SkPlatformGpuFence fFrameFences[kMaxFrameLag - 1];
+ PlatformFence fFrameFences[kMaxFrameLag - 1];
int fCurrentFenceIdx;
typedef SkNoncopyable INHERITED;