Skip to content

Is there a way to set the texture wrapping? #2605

Answered by kpreid
FishHawk asked this question in Q&A
Discussion options

You must be logged in to vote

In OpenGL, these settings are part of the texture, but in wgpu they are part of a separately created sampler, which you will use together with the texture in the shader. You construct a sampler with a SamplerDescriptor whose address_mode_* fields are the control you're looking for.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by FishHawk
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