Skip to content
Snippets Groups Projects
Verified Commit 2c69a94f authored by Tobias Frisch's avatar Tobias Frisch
Browse files

Adjusted doxygen comments for descriptor types and writes

parent eb2bd24b
No related branches found
No related tags found
1 merge request!97Resolve "Dokumentation vervollständigen"
...@@ -13,11 +13,8 @@ ...@@ -13,11 +13,8 @@
namespace vkcv namespace vkcv
{ {
/*
* All the types of descriptors (resources) that can be retrieved by the shaders enum class DescriptorType {
*/
enum class DescriptorType
{
UNIFORM_BUFFER, UNIFORM_BUFFER,
STORAGE_BUFFER, STORAGE_BUFFER,
SAMPLER, SAMPLER,
...@@ -26,13 +23,15 @@ namespace vkcv ...@@ -26,13 +23,15 @@ namespace vkcv
UNIFORM_BUFFER_DYNAMIC, UNIFORM_BUFFER_DYNAMIC,
STORAGE_BUFFER_DYNAMIC, STORAGE_BUFFER_DYNAMIC,
ACCELERATION_STRUCTURE_KHR ACCELERATION_STRUCTURE_KHR
}; };
/** /**
* Converts the descriptor types from VulkanCV (vkcv) to native Vulkan (vk). * @brief Converts the descriptor type from the frameworks enumeration
* @param[in] vkcv DescriptorType * to the Vulkan type specifier.
* @return vk DescriptorType *
*/ * @param[in] type Descriptor type
* @return Vulkan descriptor type
*/
constexpr vk::DescriptorType getVkDescriptorType(DescriptorType type) noexcept { constexpr vk::DescriptorType getVkDescriptorType(DescriptorType type) noexcept {
switch (type) switch (type)
{ {
...@@ -56,14 +55,7 @@ namespace vkcv ...@@ -56,14 +55,7 @@ namespace vkcv
return vk::DescriptorType::eMutableVALVE; return vk::DescriptorType::eMutableVALVE;
} }
} }
/*
* One binding for a descriptor set
* @param[in] a unique binding ID
* @param[in] a descriptor type
* @param[in] the number of descriptors of this type (arrays of the same type possible)
* @param[in] the shader stage where the descriptor is supposed to be retrieved
*/
struct DescriptorBinding struct DescriptorBinding
{ {
uint32_t bindingID; uint32_t bindingID;
...@@ -90,4 +82,5 @@ namespace vkcv ...@@ -90,4 +82,5 @@ namespace vkcv
DescriptorSetLayoutHandle setLayoutHandle; DescriptorSetLayoutHandle setLayoutHandle;
size_t poolIndex; size_t poolIndex;
}; };
} }
...@@ -45,10 +45,7 @@ namespace vkcv { ...@@ -45,10 +45,7 @@ namespace vkcv {
uint32_t binding; uint32_t binding;
SamplerHandle sampler; SamplerHandle sampler;
}; };
/**
* @brief Only used for RTX. Used to bind the Acceleration Structure.
*/
struct AccelerationDescriptorWrite { struct AccelerationDescriptorWrite {
inline AccelerationDescriptorWrite(uint32_t binding) : binding(binding) {}; inline AccelerationDescriptorWrite(uint32_t binding) : binding(binding) {};
uint32_t binding; uint32_t binding;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment