WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
264371
[WGSL] textureSampleGrad is not implemented
https://bugs.webkit.org/show_bug.cgi?id=264371
Summary
[WGSL] textureSampleGrad is not implemented
Mike Wyrzykowski
Reported
2023-11-07 15:42:20 PST
textureSampleGrad should map to sample which takes a gradient (page 202 of the Metal shading language spec) Open
https://webgpu.github.io/webgpu-samples/samples/normalMap
. Note the failure: MSL compilation error: Error Domain=MTLLibraryErrorDomain Code=3 "program_source:120:26: error: use of undeclared identifier 'textureSampleGrad' if ((local7.z >= textureSampleGrad(global11, global8, local7.xy, local2, local3).r)) { ^ " UserInfo={NSLocalizedDescription=program_source:120:26: error: use of undeclared identifier 'textureSampleGrad' if ((local7.z >= textureSampleGrad(global11, global8, local7.xy, local2, local3).r)) { it comes from this WGSL: // Walk the depth texture, and stop when the ray intersects the depth map var pos = vec3(startUV, 0); for (var i = 0; i < 32; i++) { if (pos.z >= textureSampleGrad(depthTexture, textureSampler, pos.xy, ddx, ddy).r) { break; // Hit the surface } pos += posDelta; } in
https://webgpu.github.io/webgpu-samples/samples/normalMap#./normalMap.wgsl
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2023-11-07 15:42:37 PST
<
rdar://problem/118084526
>
Tadeu Zagallo
Comment 2
2023-11-08 07:23:09 PST
Pull request:
https://github.com/WebKit/WebKit/pull/20162
EWS
Comment 3
2023-11-09 00:44:11 PST
Committed
270430@main
(8af46bcd0f22): <
https://commits.webkit.org/270430@main
> Reviewed commits have been landed. Closing PR #20162 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug