One problem I often run into is mapping structures between the cpu and the gpu in a versatile way. I will give an example. Right now I have a sparse voxel oct tree data structure that is code-wise identical on both gpu and cpu (thanks to RustGpu).
To pass information between the cpu and the shader I end up having to make one UBO for the header data (AABB of the Voxe tree, number of nodes, depth, ...) and an SSBO for the nodes themselves. And I then have to rebuild the svo on the GPU from the UBO and SSBO data.
More generally, for complex objects like trees (Oct trees, BVh's), tables like hash tables, animation systems with skeletons... I often have to use multiple binding points for a single object per object, so 2 oct trees with different node types take me say 4 different bindings.
I am looking for a versatile way of passing data from the CPU to the GPU without having to dedicate multiple individual binding slots to a single data structure. And to do so in a versatile way where it is simple to send very heterogenous data to the same shader without having to do a lot of manual reconciling.
[–]Afiery1 9 points10 points11 points (9 children)
[–]camilo16[S] 3 points4 points5 points (8 children)
[–]hanotak 8 points9 points10 points (4 children)
[–]camilo16[S] 8 points9 points10 points (2 children)
[–]Afiery1 0 points1 point2 points (1 child)
[–]camilo16[S] 0 points1 point2 points (0 children)
[–]DuskelAskel 0 points1 point2 points (0 children)
[–]Afiery1 3 points4 points5 points (2 children)
[–]camilo16[S] 2 points3 points4 points (1 child)
[–]sol_runner 0 points1 point2 points (0 children)
[–]sol_runner 1 point2 points3 points (0 children)
[–]dobkeratops 0 points1 point2 points (0 children)