layers: Remove default ctors for {Image,}SamplerDescriptor
These just added confusion; we already support the !immut case in the other
ctor.
V2: ImageSamplerDescriptor remaining ctor was buggy.
diff --git a/layers/descriptor_sets.cpp b/layers/descriptor_sets.cpp
index b4dcfcf..3539a83 100644
--- a/layers/descriptor_sets.cpp
+++ b/layers/descriptor_sets.cpp
@@ -331,7 +331,7 @@
descriptors_.emplace_back(new SamplerDescriptor(immut_sampler + di));
some_update_ = true; // Immutable samplers are updated at creation
} else
- descriptors_.emplace_back(new SamplerDescriptor());
+ descriptors_.emplace_back(new SamplerDescriptor(nullptr));
}
break;
}
@@ -342,7 +342,7 @@
descriptors_.emplace_back(new ImageSamplerDescriptor(immut + di));
some_update_ = true; // Immutable samplers are updated at creation
} else
- descriptors_.emplace_back(new ImageSamplerDescriptor());
+ descriptors_.emplace_back(new ImageSamplerDescriptor(nullptr));
}
break;
}
@@ -742,11 +742,6 @@
}
}
-cvdescriptorset::SamplerDescriptor::SamplerDescriptor() : sampler_(VK_NULL_HANDLE), immutable_(false) {
- updated = false;
- descriptor_class = PlainSampler;
-};
-
cvdescriptorset::SamplerDescriptor::SamplerDescriptor(const VkSampler *immut) : sampler_(VK_NULL_HANDLE), immutable_(false) {
updated = false;
descriptor_class = PlainSampler;
@@ -951,14 +946,8 @@
}
}
-cvdescriptorset::ImageSamplerDescriptor::ImageSamplerDescriptor()
- : sampler_(VK_NULL_HANDLE), immutable_(false), image_view_(VK_NULL_HANDLE), image_layout_(VK_IMAGE_LAYOUT_UNDEFINED) {
- updated = false;
- descriptor_class = ImageSampler;
-}
-
cvdescriptorset::ImageSamplerDescriptor::ImageSamplerDescriptor(const VkSampler *immut)
- : sampler_(VK_NULL_HANDLE), immutable_(true), image_view_(VK_NULL_HANDLE), image_layout_(VK_IMAGE_LAYOUT_UNDEFINED) {
+ : sampler_(VK_NULL_HANDLE), immutable_(false), image_view_(VK_NULL_HANDLE), image_layout_(VK_IMAGE_LAYOUT_UNDEFINED) {
updated = false;
descriptor_class = ImageSampler;
if (immut) {