aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/gl/GrGLPathRange.h
diff options
context:
space:
mode:
authorGravatar bungeman <bungeman@google.com>2014-08-06 11:14:31 -0400
committerGravatar bungeman <bungeman@google.com>2014-08-06 11:14:31 -0400
commitaf13c7c50efa5fda8a12a720dc77b8bc36d966a9 (patch)
tree79fd2e76ee0787d7c2022bbabf6c2b1f21a8f860 /src/gpu/gl/GrGLPathRange.h
parent4297a513268a778d1bf60890ed51386075085143 (diff)
Revert "Calculate rough approximations for nvpr path sizes"
This reverts commit 61bff7097251755bf9fa9a4ec60cc057c766b4a4. This is built on 5672da0fa54f31c9727568e9dd5fe82c6e1585bc which is causing blink test failures on canvas-lost-gpu-context.html.
Diffstat (limited to 'src/gpu/gl/GrGLPathRange.h')
-rw-r--r--src/gpu/gl/GrGLPathRange.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/gpu/gl/GrGLPathRange.h b/src/gpu/gl/GrGLPathRange.h
index 8e2df76efb..927310d651 100644
--- a/src/gpu/gl/GrGLPathRange.h
+++ b/src/gpu/gl/GrGLPathRange.h
@@ -26,8 +26,13 @@ public:
virtual ~GrGLPathRange();
GrGLuint basePathID() const { return fBasePathID; }
+
virtual void initAt(size_t index, const SkPath&);
- virtual size_t gpuMemorySize() const SK_OVERRIDE { return fGpuMemorySize; }
+
+ // TODO: Use a better approximation for the individual path sizes.
+ virtual size_t gpuMemorySize() const SK_OVERRIDE {
+ return 100 * fNumDefinedPaths;
+ }
protected:
virtual void onRelease() SK_OVERRIDE;
@@ -35,7 +40,7 @@ protected:
private:
GrGLuint fBasePathID;
- size_t fGpuMemorySize;
+ size_t fNumDefinedPaths;
typedef GrPathRange INHERITED;
};