Skip to content

How to make use of texture arrays aka "Onion textures"? #6656

Answered by cwfitzgerald
kutu-dev asked this question in Q&A
Discussion options

You must be logged in to vote

Yes, take a look at https://docs.rs/wgpu/latest/wgpu/type.TextureDescriptor.html#structfield.dimension and set the dimension to 2D, but add a depth greater than 1. This can then be used with texture_2d_array<f32> in the shader

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@kutu-dev
Comment options

@cwfitzgerald
Comment options

@kutu-dev
Comment options

Answer selected by kutu-dev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants