[Webkit-unassigned] [Bug 227586] New: ANGLE Metal Buffers created out of IOSurfaces should take the EGL_IOSURFACE_USAGE_HINT_ANGLE into account

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jul 1 08:22:59 PDT 2021


https://bugs.webkit.org/show_bug.cgi?id=227586

            Bug ID: 227586
           Summary: ANGLE Metal Buffers created out of IOSurfaces should
                    take the EGL_IOSURFACE_USAGE_HINT_ANGLE into account
           Product: WebKit
           Version: WebKit Local Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: ANGLE
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: kkinnunen at apple.com
                CC: dino at apple.com, kbr at google.com, kkinnunen at apple.com,
                    kpiddington at apple.com

ANGLE Metal Buffers created out of IOSurfaces should take the EGL_IOSURFACE_USAGE_HINT_ANGLE into account

The attribute EGL_IOSURFACE_USAGE_HINT_ANGLE may optionally be specified as
    a combination of the bits EGL_IOSURFACE_READ_HINT_ANGLE and
    EGL_IOSURFACE_WRITE_HINT_ANGLE. On the iOS Simulator platform, where
    IOSurface support is incomplete, these hints indicate whether the intent is
    to read from the IOSurface, write to it, or both. Explicitly passing 0 for
    this attribute is equivalent to setting both the read and write usage
    bits. This attribute is ignored on other platforms."

angle::Result IOSurfaceSurfaceMtl::ensureColorTextureCreated(const gl::Context *context)
{
    if (mColorTexture)
    {
        return angle::Result::Continue;
    }
    ContextMtl *contextMtl = mtl::GetImpl(context);
    ANGLE_MTL_OBJC_SCOPE
    {
        auto texDesc =
            [MTLTextureDescriptor texture2DDescriptorWithPixelFormat:mColorFormat.metalFormat
                                                               width:mSize.width
                                                              height:mSize.height
                                                           mipmapped:NO];

        texDesc.usage = MTLTextureUsageShaderRead | MTLTextureUsageRenderTarget;

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20210701/18591e36/attachment.htm>


More information about the webkit-unassigned mailing list