Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: e521d4c83bfe21177f6ff5503f6b0aa6e96ea32f
      
https://github.com/WebKit/WebKit/commit/e521d4c83bfe21177f6ff5503f6b0aa6e96ea32f
  Author: Kimmo Kinnunen <[email protected]>
  Date:   2026-09-02 (Wed, 02 Sep 2026)

  Changed paths:
    M Source/ThirdParty/ANGLE/src/libANGLE/VertexArray.cpp
    M Source/ThirdParty/ANGLE/src/tests/gl_tests/VertexAttributeTest.cpp

  Log Message:
  -----------
  ANGLE: Element limit not updated after format only VertexAttribPointer change
https://bugs.webkit.org/show_bug.cgi?id=317294
rdar://176813568

Reviewed by Dan Glastonbury.

Before, changing the type of a vertex attrib would not cause recomputation
of how many elements can be drawn. The type size affects this, as
last attrib of the buffer accesses only the type size amount of data, not
the stride amount of data.

Example buffer size == 32:
- type size == 1, stride == 28  --> buffer fits 2 elements.
- type size == 16, stride == 28 --> buffer fits 1 element.

Fix by recomputing the element count also in case the type changes.

* Source/ThirdParty/ANGLE/src/libANGLE/VertexArray.cpp:
(gl::VertexArray::bindVertexBufferImpl):
(gl::VertexArray::bindVertexBuffer):
(gl::VertexArray::setVertexAttribPointerImpl):
* Source/ThirdParty/ANGLE/src/tests/gl_tests/VertexAttributeTest.cpp:

Originally-landed-as: [email protected] (3320c0a36383). 
rdar://185367119
Canonical link: https://commits.webkit.org/320373@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to