Bug 255511 - The gl.MAX_VERTEX_UNIFORM_VECTORS has only half of its quantity available in Safari 'WebGL via Matal'
Summary: The gl.MAX_VERTEX_UNIFORM_VECTORS has only half of its quantity available in ...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGL (show other bugs)
Version: Safari 16
Hardware: iPhone / iPad iOS 16
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-04-17 04:20 PDT by QiaoLi
Modified: 2023-04-26 00:07 PDT (History)
4 users (show)

See Also:


Attachments
A demo used for reproducing the bug (3.44 MB, application/x-zip-compressed)
2023-04-17 04:20 PDT, QiaoLi
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description QiaoLi 2023-04-17 04:20:23 PDT
Created attachment 465946 [details]
A demo used for reproducing the bug

When opening the Safari feature 'WebGL via Matal', gl.getParameter(gl.MAX_VERTEX_UNIFORM_VECTORS) return value 1024.
But I can only use 512 vectors in vertex shader. When I use more, the model will be not rendering.
When make 'WebGL via Matal' off, it's ok.

Demo.zip is built from a cocos creator project.
1.cd to Demo folder, use http-server command to open a http server.
2. use safari to open http
3. you may see an empty scene, (but there is actually a model in the scene that is not displayed)
4. turn off safari  'WebGL via Metal', open http in safari again, the model will be displayed.
Comment 1 Radar WebKit Bug Importer 2023-04-24 04:21:21 PDT
<rdar://problem/108447328>
Comment 2 Kimmo Kinnunen 2023-04-24 11:02:43 PDT
Thank you for the report. Could you mention which version of the operating system you are seeing this?
This is already fixed in trunk WebKit.

I believe you could try following beta versions of Safari to verify that upcoming versions solve the issue:

macOS 13.4 beta 2 (https://beta.apple.com/sp/betaprogram)
 or
Safari Technology Preview (https://developer.apple.com/safari/resources/)
Comment 3 QiaoLi 2023-04-25 04:10:12 PDT
(In reply to Kimmo Kinnunen from comment #2)
> Thank you for the report. Could you mention which version of the operating
> system you are seeing this?
> This is already fixed in trunk WebKit.
> 
> I believe you could try following beta versions of Safari to verify that
> upcoming versions solve the issue:
> 
> macOS 13.4 beta 2 (https://beta.apple.com/sp/betaprogram)
>  or
> Safari Technology Preview (https://developer.apple.com/safari/resources/)

I test on IOS16.2 with iphon12.
Comment 4 Kimmo Kinnunen 2023-04-26 00:07:46 PDT
> I test on IOS16.2 with iphon12.
> gl.getParameter(gl.MAX_VERTEX_UNIFORM_VECTORS) return value 1024.

Does the rendering work when using 512 vectors? Would you have a test case which demonstrates working condition?

I'm asking because iOS prior to 16.5 betas advertise OES_float_texture_linear, which the page uses. Float texture filtering does not work on iOS. This extension should be disabled in 16.5 beta. The demo page should work on 16.5 beta, as per my testing.