diff options
author | 2017-12-04 11:45:51 -0700 | |
---|---|---|
committer | 2017-12-05 21:12:48 +0000 | |
commit | a3e9271ec41db6c3b6886e50053f37d345ab1d5c (patch) | |
tree | 97772078cf13d954ac4ba135fcd20feda6bb22e1 /src/gpu/ccpr/GrCCPRQuadraticShader.h | |
parent | 60691a5127852631b03250f15fa6cda9a504befc (diff) |
CCPR: Eliminate texel buffers
Points cost 8 bytes and indices cost 4. If a point is accessed twice,
it's a wash whether we duplicate it or index. This change eliminates
texel buffers by duplicating points across instance arrays. This
reduces our dependence on extensions as well as getting rid of our
indirect memory access pattern in vertex shaders.
As a result of this change, memory usage by GPU buffers will only be a
fraction larger at worst, and slightly better at best.
Bug: skia:
Cq-Include-Trybots: skia.primary:Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-SKNX_NO_SIMD
Change-Id: I3c7f03772edd4f850d5fdd7b55552647335c1b52
Reviewed-on: https://skia-review.googlesource.com/79185
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Diffstat (limited to 'src/gpu/ccpr/GrCCPRQuadraticShader.h')
-rw-r--r-- | src/gpu/ccpr/GrCCPRQuadraticShader.h | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/src/gpu/ccpr/GrCCPRQuadraticShader.h b/src/gpu/ccpr/GrCCPRQuadraticShader.h index 38dd14e737..4877edec44 100644 --- a/src/gpu/ccpr/GrCCPRQuadraticShader.h +++ b/src/gpu/ccpr/GrCCPRQuadraticShader.h @@ -24,10 +24,6 @@ class GrCCPRQuadraticShader : public GrCCPRCoverageProcessor::Shader { protected: int getNumInputPoints() const final { return 3; } - void appendInputPointFetch(const GrCCPRCoverageProcessor&, GrGLSLShaderBuilder*, - const TexelBufferHandle& pointsBuffer, - const char* pointId) const override; - void emitWind(GrGLSLShaderBuilder*, const char* pts, const char* outputWind) const final; void emitSetupCode(GrGLSLShaderBuilder*, const char* pts, const char* segmentId, |