aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoralan-baker <alanbaker@google.com>2020-12-09 09:11:37 -0500
committerGitHub <noreply@github.com>2020-12-09 09:11:37 -0500
commit7c19feb333b5e74ec0d346f22456531a38bb43ef (patch)
tree613cc94dac14a280b338e3f0ca66bac32837daa1
parent758f918f2b49588ba8b1e58f08eaa833e96b2fa4 (diff)
downloadamber-7c19feb333b5e74ec0d346f22456531a38bb43ef.tar.gz
Don't add an amber sampler for sampled images (#928)
When adding a buffer for an image, do not add a sampler for sampled image binding (only for combined sampled image bindings) Fixes #927
-rw-r--r--src/vulkan/pipeline.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vulkan/pipeline.cc b/src/vulkan/pipeline.cc
index 4f4075b..e0b875c 100644
--- a/src/vulkan/pipeline.cc
+++ b/src/vulkan/pipeline.cc
@@ -320,7 +320,7 @@ Result Pipeline::AddBufferDescriptor(const BufferCommand* cmd) {
auto image_desc = MakeUnique<ImageDescriptor>(
cmd->GetBuffer(), desc_type, device_, cmd->GetBaseMipLevel(),
cmd->GetDescriptorSet(), cmd->GetBinding());
- if (cmd->IsSampledImage() || cmd->IsCombinedImageSampler())
+ if (cmd->IsCombinedImageSampler())
image_desc->SetAmberSampler(cmd->GetSampler());
descriptors.push_back(std::move(image_desc));
} else {