aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrProgramDesc.cpp
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2018-07-12 14:53:49 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-07-13 00:45:54 +0000
commit662ea4baba570d2f21a7b33d268204e9bdfa7fb9 (patch)
tree71da861d0d9b8f014e7f09f89b122480e067e8c0 /src/gpu/GrProgramDesc.cpp
parent13ac194dbf9968d356e580b85420f1314f453a10 (diff)
Remove texel buffer support.
Change-Id: Ia6f21afe714208979a5bc384e436b28ea2b9a297 Reviewed-on: https://skia-review.googlesource.com/141051 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/gpu/GrProgramDesc.cpp')
-rw-r--r--src/gpu/GrProgramDesc.cpp15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/gpu/GrProgramDesc.cpp b/src/gpu/GrProgramDesc.cpp
index e5da3be6ee..d2dce7c4e5 100644
--- a/src/gpu/GrProgramDesc.cpp
+++ b/src/gpu/GrProgramDesc.cpp
@@ -58,10 +58,8 @@ static uint16_t sampler_key(GrSLType samplerType, GrPixelConfig config, GrShader
static void add_sampler_and_image_keys(GrProcessorKeyBuilder* b, const GrResourceIOProcessor& proc,
const GrShaderCaps& caps) {
int numTextureSamplers = proc.numTextureSamplers();
- int numBuffers = proc.numBuffers();
- int numUniforms = numTextureSamplers + numBuffers;
// Need two bytes per key.
- int word32Count = (numUniforms + 1) / 2;
+ int word32Count = (numTextureSamplers + 1) / 2;
if (0 == word32Count) {
return;
}
@@ -74,14 +72,9 @@ static void add_sampler_and_image_keys(GrProcessorKeyBuilder* b, const GrResourc
k16[j] = sampler_key(tex->texturePriv().samplerType(), tex->config(), sampler.visibility(),
caps);
}
- for (int i = 0; i < numBuffers; ++i, ++j) {
- const GrResourceIOProcessor::BufferAccess& access = proc.bufferAccess(i);
- k16[j] = sampler_key(kBufferSampler_GrSLType, access.texelConfig(), access.visibility(),
- caps);
- }
- // zero the last 16 bits if the number of uniforms for samplers and image storages is odd.
- if (numUniforms & 0x1) {
- k16[numUniforms] = 0;
+ // zero the last 16 bits if the number of uniforms for samplers is odd.
+ if (numTextureSamplers & 0x1) {
+ k16[numTextureSamplers] = 0;
}
}