commit | e2e71c2df4e72e897bbe745752be0444aee5c29f | [log] [tgz] |
---|---|---|
author | cdalton <cdalton@nvidia.com> | Thu Apr 07 18:13:29 2016 -0700 |
committer | Commit bot <commit-bot@chromium.org> | Thu Apr 07 18:13:29 2016 -0700 |
tree | 60591705d9f4f99246c156b8a4f98d28ce376af6 | |
parent | 8dea4e41a11fd526fa533396173f72af0f9042d7 [diff] [blame] |
Track GL buffer state based on unique resource ID Reworks GrGLGpu to track GL buffer state based on the unique GrGpuResource ID. This eliminates the need to notify the gpu object whenever a buffer is deleted. This change also allows us to remove the type specifier from GrBuffer. At this point a buffer is just a chunk of memory, and the type given at creation time is just a suggestion to the GL backend about which target to bind to for updates. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1854283004 Committed: https://skia.googlesource.com/skia/+/deacc97bc63513b5eacaf21f858727f6e8b98ce5 Review URL: https://codereview.chromium.org/1854283004
diff --git a/src/gpu/GrBufferAllocPool.cpp b/src/gpu/GrBufferAllocPool.cpp index 278cf86..d19604c 100644 --- a/src/gpu/GrBufferAllocPool.cpp +++ b/src/gpu/GrBufferAllocPool.cpp
@@ -319,7 +319,7 @@ // Shouldn't have to use this flag (https://bug.skia.org/4156) static const uint32_t kFlags = GrResourceProvider::kNoPendingIO_Flag; - return rp->createBuffer(fBufferType, size, kDynamic_GrAccessPattern, kFlags); + return rp->createBuffer(size, fBufferType, kDynamic_GrAccessPattern, kFlags); } ////////////////////////////////////////////////////////////////////////////////