diff options
author | Brian Salomon <bsalomon@google.com> | 2016-11-17 11:38:22 -0500 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2016-11-17 17:18:53 +0000 |
commit | 0bbecb21ab82b3d742c491780bcc2e74be03efed (patch) | |
tree | 0355eca170a7cb268b27049dd158886d7f62cb87 /src/gpu/GrProgramDesc.cpp | |
parent | 9de097639f04e5a18da2d2b123dace9d24ab50e4 (diff) |
Rename GrTextureAccess to GrProcessor::TextureSampler.
Renames vars and methods that used the work "access" to refer to this type.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4931
Change-Id: Ibcf488fbd445c5119fc13d190544cd98981bdbee
Reviewed-on: https://skia-review.googlesource.com/4931
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'src/gpu/GrProgramDesc.cpp')
-rw-r--r-- | src/gpu/GrProgramDesc.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gpu/GrProgramDesc.cpp b/src/gpu/GrProgramDesc.cpp index ea2a528319..d9afbac85b 100644 --- a/src/gpu/GrProgramDesc.cpp +++ b/src/gpu/GrProgramDesc.cpp @@ -34,8 +34,8 @@ static uint16_t sampler_key(GrSLType samplerType, GrPixelConfig config, GrShader static void add_sampler_keys(GrProcessorKeyBuilder* b, const GrProcessor& proc, const GrGLSLCaps& caps) { - int numTextures = proc.numTextures(); - int numSamplers = numTextures + proc.numBuffers(); + int numTextureSamplers = proc.numTextureSamplers(); + int numSamplers = numTextureSamplers + proc.numBuffers(); // Need two bytes per key (swizzle, sampler type, and precision). int word32Count = (numSamplers + 1) / 2; if (0 == word32Count) { @@ -43,14 +43,14 @@ static void add_sampler_keys(GrProcessorKeyBuilder* b, const GrProcessor& proc, } uint16_t* k16 = SkTCast<uint16_t*>(b->add32n(word32Count)); int i = 0; - for (; i < numTextures; ++i) { - const GrTextureAccess& access = proc.textureAccess(i); - const GrTexture* tex = access.getTexture(); + for (; i < numTextureSamplers; ++i) { + const GrProcessor::TextureSampler& textureSampler = proc.textureSampler(i); + const GrTexture* tex = textureSampler.getTexture(); k16[i] = sampler_key(tex->texturePriv().samplerType(), tex->config(), - access.getVisibility(), caps); + textureSampler.getVisibility(), caps); } for (; i < numSamplers; ++i) { - const GrBufferAccess& access = proc.bufferAccess(i - numTextures); + const GrBufferAccess& access = proc.bufferAccess(i - numTextureSamplers); k16[i] = sampler_key(kBufferSampler_GrSLType, access.texelConfig(), access.visibility(), caps); } |