⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 267685 in webkit


Ignore:
Timestamp:
Sep 27, 2020, 1:00:47 PM (6 years ago)
Author:
Alan Coon
Message:

Cherry-pick r267520. rdar://problem/69594405

REGRESSION: Textures Fail to Render in WebGL from HLS Stream [iOS 14]
https://bugs.webkit.org/show_bug.cgi?id=215908
<rdar://problem/68000962>

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2020-09-24
Reviewed by Dean Jackson.

Disable ANGLE workers until EAGL implementation is more complete.
Current implementation fails to compile any shader, since the
compilation happens in the worker thread and worker EAGL context
which does not use the same sharegroup as the main context.
The shader objects are created in the main context but the shader
source setting and compilation happens in the worker context.
EAGL needs a flush between state changes, and adding that
correctly is a bigger change to be done later.

Use sized formats when calling [EAGLContext -texImageIOSurface]
from EGL_ANGLE_iosurface_client_buffer code. The texImageIOSurface
accepts parameters with glTexImage2D logic. On ES3, some of the
internal formats must be sized formats. The EAGLContext instantiated
by ANGLE is ES3, even if the ANGLE context would be ES2.

No tests added since this should be caught with the many video
related tests. It's unclear why this is not the case -- at
least on real hw. This is to be investigated later, too.

  • src/libANGLE/renderer/driver_utils.h: (rx::IsIOS):
  • src/libANGLE/renderer/gl/eagl/IOSurfaceSurfaceEAGL.mm:
  • src/libANGLE/renderer/gl/renderergl_utils.cpp: (rx::nativegl_gl::InitializeFeatures):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@267520 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Location:
branches/safari-610-branch/Source/ThirdParty/ANGLE
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/safari-610-branch/Source/ThirdParty/ANGLE/ChangeLog

    r266869 r267685  
     12020-09-27  Alan Coon  <alancoon@apple.com>
     2
     3        Cherry-pick r267520. rdar://problem/69594405
     4
     5    REGRESSION: Textures Fail to Render in WebGL from HLS Stream [iOS 14]
     6    https://bugs.webkit.org/show_bug.cgi?id=215908
     7    <rdar://problem/68000962>
     8   
     9    Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2020-09-24
     10    Reviewed by Dean Jackson.
     11   
     12    Disable ANGLE workers until EAGL implementation is more complete.
     13    Current implementation fails to compile any shader, since the
     14    compilation happens in the worker thread and worker EAGL context
     15    which does not use the same sharegroup as the main context.
     16    The shader objects are created in the main context but the shader
     17    source setting and compilation happens in the worker context.
     18    EAGL needs a flush between state changes, and adding that
     19    correctly is a bigger change to be done later.
     20   
     21    Use sized formats when calling [EAGLContext -texImageIOSurface]
     22    from EGL_ANGLE_iosurface_client_buffer code. The texImageIOSurface
     23    accepts parameters with glTexImage2D logic. On ES3, some of the
     24    internal formats must be sized formats. The EAGLContext instantiated
     25    by ANGLE is ES3, even if the ANGLE context would be ES2.
     26   
     27    No tests added since this should be caught with the many video
     28    related tests. It's unclear why this is not the case -- at
     29    least on real hw. This is to be investigated later, too.
     30   
     31    * src/libANGLE/renderer/driver_utils.h:
     32    (rx::IsIOS):
     33    * src/libANGLE/renderer/gl/eagl/IOSurfaceSurfaceEAGL.mm:
     34    * src/libANGLE/renderer/gl/renderergl_utils.cpp:
     35    (rx::nativegl_gl::InitializeFeatures):
     36   
     37    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@267520 268f45cc-cd09-0410-ab3c-d52691b4dbfc
     38
     39    2020-09-24  Kimmo Kinnunen  <kkinnunen@apple.com>
     40
     41            REGRESSION: Textures Fail to Render in WebGL from HLS Stream [iOS 14]
     42            https://bugs.webkit.org/show_bug.cgi?id=215908
     43            <rdar://problem/68000962>
     44
     45            Reviewed by Dean Jackson.
     46
     47            Disable ANGLE workers until EAGL implementation is more complete.
     48            Current implementation fails to compile any shader, since the
     49            compilation happens in the worker thread and worker EAGL context
     50            which does not use the same sharegroup as the main context.
     51            The shader objects are created in the main context but the shader
     52            source setting and compilation happens in the worker context.
     53            EAGL needs a flush between state changes, and adding that
     54            correctly is a bigger change to be done later.
     55
     56            Use sized formats when calling [EAGLContext -texImageIOSurface]
     57            from EGL_ANGLE_iosurface_client_buffer code. The texImageIOSurface
     58            accepts parameters with glTexImage2D logic. On ES3, some of the
     59            internal formats must be sized formats. The EAGLContext instantiated
     60            by ANGLE is ES3, even if the ANGLE context would be ES2.
     61
     62            No tests added since this should be caught with the many video
     63            related tests. It's unclear why this is not the case -- at
     64            least on real hw. This is to be investigated later, too.
     65
     66            * src/libANGLE/renderer/driver_utils.h:
     67            (rx::IsIOS):
     68            * src/libANGLE/renderer/gl/eagl/IOSurfaceSurfaceEAGL.mm:
     69            * src/libANGLE/renderer/gl/renderergl_utils.cpp:
     70            (rx::nativegl_gl::InitializeFeatures):
     71
    1722020-09-10  Alan Coon  <alancoon@apple.com>
    273
  • branches/safari-610-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/driver_utils.h

    r265064 r267685  
    165165}
    166166
     167inline bool IsIOS()
     168{
     169#if defined(ANGLE_PLATFORM_IOS)
     170    return true;
     171#else
     172    return false;
     173#endif
     174}
    167175struct OSVersion
    168176{
  • branches/safari-610-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/eagl/IOSurfaceSurfaceEAGL.mm

    r262036 r267685  
    4949
    5050static const IOSurfaceFormatInfo kIOSurfaceFormats[] = {
    51     {GL_RED,      GL_UNSIGNED_BYTE,  1, GL_RED,  GL_RED,  GL_UNSIGNED_BYTE },
    52     {GL_R16UI,    GL_UNSIGNED_SHORT, 2, GL_RED,  GL_RED,  GL_UNSIGNED_SHORT},
    53     {GL_RG,       GL_UNSIGNED_BYTE,  2, GL_RG,   GL_RG,   GL_UNSIGNED_BYTE },
     51    {GL_RED,      GL_UNSIGNED_BYTE,  1, GL_R8,  GL_RED,  GL_UNSIGNED_BYTE },
     52    {GL_R16UI,    GL_UNSIGNED_SHORT, 2, GL_R16UI, GL_RED_INTEGER,  GL_UNSIGNED_SHORT},
     53    {GL_RG,       GL_UNSIGNED_BYTE,  2, GL_RG8,  GL_RG,   GL_UNSIGNED_BYTE },
    5454    {GL_RGB,      GL_UNSIGNED_BYTE,  4, GL_RGBA, GL_BGRA, GL_UNSIGNED_BYTE },
    5555    {GL_BGRA_EXT, GL_UNSIGNED_BYTE,  4, GL_RGBA, GL_BGRA, GL_UNSIGNED_BYTE },
  • branches/safari-610-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/renderergl_utils.cpp

    r265064 r267685  
    16621662    // crbug.com/922936
    16631663    ANGLE_FEATURE_CONDITION(features, disableWorkerContexts,
    1664                             (IsWindows() && (isIntel || isAMD)) || (IsLinux() && isNvidia));
     1664                            (IsWindows() && (isIntel || isAMD)) || (IsLinux() && isNvidia) || IsIOS());
    16651665
    16661666    bool limitMaxTextureSize = isIntel && IsLinux() && GetLinuxOSVersion() < OSVersion(5, 0, 0);
Note: See TracChangeset for help on using the changeset viewer.