Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 2f1c7a102f89c39591bcfc6593b3415ed86d6342
      
https://github.com/WebKit/WebKit/commit/2f1c7a102f89c39591bcfc6593b3415ed86d6342
  Author: Kimmo Kinnunen <kkinnu...@apple.com>
  Date:   2025-05-22 (Thu, 22 May 2025)

  Changed paths:
    M Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/TextureMtl.mm
    M Source/ThirdParty/ANGLE/src/tests/gl_tests/MipmapTest.cpp

  Log Message:
  -----------
  WebGL: Generating mipmaps for 3D textures with depth greater than width, 
height causes crash
https://bugs.webkit.org/show_bug.cgi?id=289677
rdar://145485379

Reviewed by Mike Wyrzykowski.

When 3D texture depth > max(2 * w, 2 * h), the last levels ended up
calling the mipmap generation function with sourceWidth=1,
sourceHeight=1, sourceDepth=1. This is unanticipated, as that mipmap
is the last mipmap level and cannot be a source for mipmap generation.
This leads to the mipmap generator to select a nullptr function
and calling it.

This happened in certain conditions depending on features, internal
format and texture size. The conditions would make the mipmap generation
take the CPU mipmap generation path.

* Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/TextureMtl.mm:
(rx::TextureMtl::generateMipmapCPU):
* Source/ThirdParty/ANGLE/src/tests/gl_tests/MipmapTest.cpp:

Originally-landed-as: 289651.278@safari-7621-branch (d3824e9cbc6b). 
rdar://151707084
Canonical link: https://commits.webkit.org/295297@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to