upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/test/bindless_sizing_test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/test/bindless_sizing_test.cpp')
-rw-r--r--runtime/test/bindless_sizing_test.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/runtime/test/bindless_sizing_test.cpp b/runtime/test/bindless_sizing_test.cpp
index 4553f25b6..2ceecf76f 100644
--- a/runtime/test/bindless_sizing_test.cpp
+++ b/runtime/test/bindless_sizing_test.cpp
@@ -1,6 +1,6 @@
1// bindless::size_bindings with synthetic device limits: no GPU. The counts of set 0 come from the device's descriptor 1// bindless::size_bindings with synthetic device limits: no GPU. The counts of set 0 come from the device's descriptor
2// limits (vulkan_bindless.h): today's sizes where a device is at them, larger 2D, sampler and storage arrays where it 2// limits (vulkan_bindless.h): today's sizes where a device is at them, larger image, sampler and storage arrays where
3// has room, and less where it is below them. 3// it has room, and less where it is below them.
4#ifndef VK_NO_PROTOTYPES 4#ifndef VK_NO_PROTOTYPES
5#define VK_NO_PROTOTYPES 5#define VK_NO_PROTOTYPES
6#endif 6#endif
@@ -103,8 +103,13 @@ int main() {
103 EXPECT(f.counts[bindless::sampler_binding] == 4000 - bindless::reserved_samplers); 103 EXPECT(f.counts[bindless::sampler_binding] == 4000 - bindless::reserved_samplers);
104 EXPECT(f.counts[bindless::sampler_binding] > 2048); // a full sampler heap and the fallback 104 EXPECT(f.counts[bindless::sampler_binding] > 2048); // a full sampler heap and the fallback
105 EXPECT(storage(f, D::dim_2d) == bindless::max_storage_indices); 105 EXPECT(storage(f, D::dim_2d) == bindless::max_storage_indices);
106 EXPECT(storage(f, D::dim_2d_array) == 1024 && storage(f, D::dim_3d) == 256 && storage(f, D::dim_1d) == 256); 106 // The other dimensions grow too (a title's cube maps, texture arrays and 1D lookups outnumber the defaults);
107 EXPECT(count(f, D::dim_2d_array) == 1024 && count(f, D::dim_3d) == 256 && count(f, D::dim_1d) == 256); 107 // their storage arrays hold as many indices as the 2D one.
108 EXPECT(count(f, D::dim_2d_array) == bindless::max_2d_array_images &&
109 count(f, D::dim_3d) == bindless::max_3d_images && count(f, D::dim_1d) == bindless::max_1d_images);
110 EXPECT(storage(f, D::dim_2d_array) == bindless::max_storage_indices &&
111 storage(f, D::dim_3d) == bindless::max_storage_indices &&
112 storage(f, D::dim_1d) == bindless::max_storage_indices);
108 EXPECT(f.ms_samples[0] == VK_SAMPLE_COUNT_4_BIT && f.ms_samples[2] == VK_SAMPLE_COUNT_4_BIT); 113 EXPECT(f.ms_samples[0] == VK_SAMPLE_COUNT_4_BIT && f.ms_samples[2] == VK_SAMPLE_COUNT_4_BIT);
109 EXPECT(storage_consistent(f)); 114 EXPECT(storage_consistent(f));
110 if (update_after_bind) 115 if (update_after_bind)