diff --git a/data/shaders/glsl/rayquery/scene.frag b/data/shaders/glsl/rayquery/scene.frag index 059fc4d3..a0273b83 100644 --- a/data/shaders/glsl/rayquery/scene.frag +++ b/data/shaders/glsl/rayquery/scene.frag @@ -25,7 +25,7 @@ void main() outFragColor = vec4(diffuse, 1.0); rayQueryEXT rayQuery; - rayQueryInitializeEXT(rayQuery, topLevelAS, gl_RayFlagsTerminateOnFirstHitEXT | gl_RayFlagsSkipAABBEXT, 0xFF, inWorldPos, 0.01, L, 1000.0); + rayQueryInitializeEXT(rayQuery, topLevelAS, gl_RayFlagsTerminateOnFirstHitEXT, 0xFF, inWorldPos, 0.01, L, 1000.0); // Traverse the acceleration structure and store information about the first intersection (if any) rayQueryProceedEXT(rayQuery); diff --git a/data/shaders/glsl/rayquery/scene.frag.spv b/data/shaders/glsl/rayquery/scene.frag.spv index feae30ab..0a90da47 100644 Binary files a/data/shaders/glsl/rayquery/scene.frag.spv and b/data/shaders/glsl/rayquery/scene.frag.spv differ diff --git a/examples/rayquery/rayquery.cpp b/examples/rayquery/rayquery.cpp index a432fb3a..51bff8b1 100644 --- a/examples/rayquery/rayquery.cpp +++ b/examples/rayquery/rayquery.cpp @@ -1,7 +1,7 @@ /* * Vulkan Example - Using ray queries for hardware accelerated ray tracing queries in a fragment shader * -* Copyright (C) 2020 by Sascha Willems - www.saschawillems.de +* Copyright (C) 2020-2022 by Sascha Willems - www.saschawillems.de * * This code is licensed under the MIT license (MIT) (http://opensource.org/licenses/MIT) */ @@ -289,11 +289,10 @@ public: void setupDescriptorPool() { std::vector poolSizes = { - vks::initializers::descriptorPoolSize(VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, 3), - vks::initializers::descriptorPoolSize(VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, 3), - vks::initializers::descriptorPoolSize(VK_DESCRIPTOR_TYPE_ACCELERATION_STRUCTURE_KHR, 3) + vks::initializers::descriptorPoolSize(VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, 1), + vks::initializers::descriptorPoolSize(VK_DESCRIPTOR_TYPE_ACCELERATION_STRUCTURE_KHR, 1) }; - VkDescriptorPoolCreateInfo descriptorPoolInfo = vks::initializers::descriptorPoolCreateInfo(poolSizes, 3); + VkDescriptorPoolCreateInfo descriptorPoolInfo = vks::initializers::descriptorPoolCreateInfo(poolSizes, 1); VK_CHECK_RESULT(vkCreateDescriptorPool(device, &descriptorPoolInfo, nullptr, &descriptorPool)); }