diff options
author | bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2013-02-08 21:22:44 +0000 |
---|---|---|
committer | bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2013-02-08 21:22:44 +0000 |
commit | 6438695222333981fafee9c8c09f3bf51dce3816 (patch) | |
tree | 9ab75e22f28093d433bac25f3f8a60dbedb1e750 /include | |
parent | 6577cd37c73bd6e3bbdb7b7af2fc625a2cd69b39 (diff) |
Revert 7625 until after M26 due to a mix of perf changes.
git-svn-id: http://skia.googlecode.com/svn/trunk@7683 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include')
-rw-r--r-- | include/gpu/GrConfig.h | 9 | ||||
-rw-r--r-- | include/gpu/GrUserConfig.h | 11 |
2 files changed, 19 insertions, 1 deletions
diff --git a/include/gpu/GrConfig.h b/include/gpu/GrConfig.h index d929d580ac..00e77eadb3 100644 --- a/include/gpu/GrConfig.h +++ b/include/gpu/GrConfig.h @@ -316,6 +316,15 @@ inline void GrCrash(const char* msg) { GrPrintf(msg); GrAlwaysAssert(false); } #endif /** + * GR_STATIC_RECT_VB controls whether rects are drawn by issuing a vertex + * for each corner or using a static vb that is positioned by modifying the + * view / texture matrix. + */ +#if !defined(GR_STATIC_RECT_VB) + #define GR_STATIC_RECT_VB 1 +#endif + +/** * GR_GEOM_BUFFER_LOCK_THRESHOLD gives a threshold (in bytes) for when Gr should * lock a GrGeometryBuffer to update its contents. It will use lock() if the * size of the updated region is greater than the threshold. Otherwise it will diff --git a/include/gpu/GrUserConfig.h b/include/gpu/GrUserConfig.h index b9df083c48..594889b1a7 100644 --- a/include/gpu/GrUserConfig.h +++ b/include/gpu/GrUserConfig.h @@ -21,7 +21,16 @@ #define GR_DEBUG 1 #endif -/* +/** + * When drawing rects this causes Ganesh to use a vertex buffer containing + * a unit square that is positioned by a matrix. Enable on systems where + * emitting per-rect-draw verts is more expensive than constant/matrix + * updates. Defaults to 0. + */ +//#define GR_STATIC_RECT_VB 1 + + +/** * This gives a threshold in bytes of when to lock a GrGeometryBuffer vs using * updateData. (Note the depending on the underlying 3D API the update functions * may always be implemented using a lock) |