Change integer texture parameters to unsigned - #2722
Merged
Merged
Conversation
Contributor
litherum
reviewed
Apr 2, 2022
| textureSample(t: texture_2d<f32>, s: sampler, coords: vec2<f32>, offset: vec2<i32>) -> vec4<f32> | ||
| textureSample(t: texture_2d_array<f32>, s: sampler, coords: vec2<f32>, array_index: i32) -> vec4<f32> | ||
| textureSample(t: texture_2d_array<f32>, s: sampler, coords: vec2<f32>, array_index: i32, offset: vec2<i32>) -> vec4<f32> | ||
| textureSample(t: texture_2d<f32>, s: sampler, coords: vec2<f32>, offset: vec2<u32>) -> vec4<f32> |
Contributor
There was a problem hiding this comment.
I'm confused. Offsets can be negative.
Contributor
Author
There was a problem hiding this comment.
Good catch, got a little overzealous with search and replace.
Contributor
Contributor
WGSL meeting minutes 2022-04-12
|
Fixes gpuweb#2570 * Returned values are always unsigned now * Added overloads for texture functions that had i32 based parameters (other than `offset`) to have an equivalent u32 version
alan-baker
force-pushed
the
texture-integer-sign
branch
from
April 14, 2022 15:11
6017ee4 to
daba2c7
Compare
Contributor
kdashg
approved these changes
Apr 15, 2022
Contributor
WGSL meeting minutes 2022-05-03
|
jdarpinian
pushed a commit
to jdarpinian/gpuweb
that referenced
this pull request
Aug 12, 2022
Fixes gpuweb#2570 * Returned values are always unsigned now * Added overloads for texture functions that had i32 based parameters (other than `offset`) to have an equivalent u32 version
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #2570
signed to unsigned
accepted in these functions
I plan to leave #2588 open for now, but this is a more reasonable state than the current one and likely easier to get consensus on.