cocos-engine icon indicating copy to clipboard operation
cocos-engine copied to clipboard

IOS 26 rendering problem (missing objects)

Open GeTechG opened this issue 3 months ago • 2 comments

Cocos Creator version

3.8.7

System information

IOS 26, webgl1

Issue description

This is a issue that affects all the glitches I've noticed in iOS 26, and they're all related to rendering. I think they're all interconnected. There are several different problems:

  1. Sprites with UIOpacity disappear when the orientation changes — this problem seems to be solved by updating parameters such as opacity after the orientation has changed.
  2. WebGL: INVALID_OPERATION: glDrawElements: Vertex buffer is not big enough for the draw call. I don't know exactly what causes it yet, but in my case, literally one Sprite caused the problem in the production code. If you hide it, everything is fine. I will try to recreate the test scene later, but I couldn't recreate it on a bare project. This has already been discussed on the forum, but it didn't work for me and the bug didn't show up. If you manage to recreate it on a blank project, please send it to us.

Relevant error log output

WebGL: INVALID_OPERATION: glDrawElements: Vertex buffer is not big enough for the draw call.

Steps to reproduce

The following option was suggested for the forum, but it did not reveal the problem for me:

Reproduction method:
Attach an image resource (or an atlas) to a UI node.  
Then, in the code, create two sprites, for example:

const node = new Node();
node.addComponent(Sprite).spriteFrame = this._atlas.getSpriteFrame("icon_0");
this.node.addChild(node);

After that, toggle the visibility of these two nodes in turns, for example:

let flag = false;
this.schedule(() => {
    flag = !flag;
    node_0.active = flag;
    node_1.active = !flag;
}, 0.2);

Minimal reproduction project

No response

GeTechG avatar Nov 25 '25 06:11 GeTechG

I am also unable to reproduce through the example code you mentioned, but in a production environment, this problem occurs particularly frequently when there are many images or spine of the same resource. It's just a rendering issue that doesn't affect the real logic of the game, but a certain node miraculously hasn't been rendered.

LTJ-CS avatar Nov 26 '25 03:11 LTJ-CS

When the problem arises, such as losing a spine in the scene, I immediately open a UI interface, and the same spine in the UI interface cannot be rendered. If I remove one of them, the performance will be normal. Similarly, in one of my UI, there are many bubbles with the same image, and sometimes the last few consecutive bubbles (which should be from the same batch) cannot be rendered.

LTJ-CS avatar Nov 26 '25 04:11 LTJ-CS

I have the same issue. Some sprites stop rendering randomly on ios26 webgl (safari and chrome). They reappear on scene change. (looks like an entier batch fails to render).I don't get the buffer error, it fails silently. Tested the same project build (html with canvas and webgl2) on windows desktop and it runs fine (will test on android too as soon as I get a device).

raduangelescu avatar Dec 16 '25 20:12 raduangelescu