676 {
677
678 if (keyContext.recorder() && !imgData.fTextureProxy) {
680 return;
681 }
682
683 const Caps* caps = keyContext.caps();
684 const bool doTilingInHw = !imgData.fSampling.useCubic && can_do_tiling_in_hw(caps, imgData);
685
686 if (doTilingInHw) {
687 add_hw_image_uniform_data(keyContext.dict(), imgData, gatherer);
689 } else if (imgData.fSampling.useCubic) {
690 add_cubic_image_uniform_data(keyContext.dict(), imgData, gatherer);
692 } else {
693 add_image_uniform_data(keyContext.dict(), imgData, gatherer);
695 }
696
698
699
700
701 ImmutableSamplerInfo
info = caps->getImmutableSamplerInfo(imgData.fTextureProxy.get());
702 SamplerDesc samplerDesc {imgData.fSampling,
703 doTilingInHw ? imgData.fTileModes : kDefaultTileModes,
705 gatherer->add(imgData.fTextureProxy, samplerDesc);
706 add_sampler_data_to_key(
builder, samplerDesc);
707}
static void info(const char *fmt,...) SK_PRINTF_LIKE(1