Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Will CoreGraphics support Metal on Apple Devices?

I have read that Core Graphics is based on OpenGL ES and uses the Quartz Drawing Engine on Apple devices (iOS, OSX)

However with the upcoming deprecation of OpenGL ES for Metal, will Core Graphics be updated to support Metal and/or software rendering for coming iOS/OSX devices?

like image 660
Dr. Andrew Burnett-Thompson Avatar asked Nov 16 '18 17:11

Dr. Andrew Burnett-Thompson


People also ask

Does Core Graphics use Metal?

A few Apple frameworks, including Core Image, use Metal under the hood to delegate graphic workloads to the GPU, while Core ML uses Metal for performing its low-level operations on the GPU.

Can you use Metal on Mac?

Metal has been available on macOS since 2015 for Macs (2012 models or later) running OS X El Capitan. And Metal 2 (the second version of Metal) supports macOS High Sierra and later since 2017. For the Metal 3, Apple says it supports Apple silicon Macs and macOS Ventura or later.

What is Apple Metal support?

Metal powers hardware-accelerated graphics on Apple platforms by providing a low-overhead API, rich shading language, tight integration between graphics and compute, and an unparalleled suite of GPU profiling and debugging tools.

Does Safari use Metal?

Safari now runs WebGL on top of Metal on recent iOS and macOS devices. Collaborative work continues among the Apple and Google engineering teams, including adopting top-of-tree ANGLE into WebKit, creating a common codebase for development going forward, and switching Chrome to use ANGLE's Metal backend as well.


1 Answers

First, Core Graphics doesn't "use" Quartz. "Core Graphics" and "Quartz" are just two names for the same thing. They are equivalent.

Second, Apple doesn't promise what technology Core Graphics uses under the hood. They've occasionally touted the acceleration they were able to accomplish by using some particular technology, but that's marketing — marketing to developers, but marketing nonetheless — not a design contract. They reserve the right and ability to change how Core Graphics is implemented, and have done so often. Any developer who writes code which depends on the specific implementation is risking having their code break with future updates to the OS. Developers should only rely on the design contract in the documentation and headers.

It is very likely that Core Graphics is already using Metal under the hood. It makes no difference to you as a developer or user whether it is or isn't.

Finally, Core Graphics has not been deprecated. That means that there's no reason to expect it to go away, break, or lose functionality any time soon.

like image 183
Ken Thomases Avatar answered Nov 07 '22 22:11

Ken Thomases