Godot: OpenGL is deprecated in macOS 10.14 and iOS 12

Created on 4 Jun 2018  Â·  23Comments  Â·  Source: godotengine/godot

Godot version:

Any

OS/device including version:

OSX 10.14+
iOS 12+

Issue description:

https://developer.apple.com/macos/whats-new/

Deprecations and Removed APIs

Periodically, Apple adds deprecation macros to APIs to indicate that those APIs should no longer be used in active development. When a deprecation occurs, it’s not an immediate end of life for the specified API. Instead, it is the beginning of a grace period for transitioning from that API and to newer and more modern replacements. Deprecated APIs typically remain present and usable in the system for a reasonable time past the release in which they were deprecated. However, active development on them ceases, and the APIs receive only minor changes to accommodate security patches or to fix other critical bugs. Deprecated APIs may be removed entirely from a future version of the operating system.

As a developer, avoid using deprecated APIs in your code as soon as possible. At a minimum, new code you write should never use deprecated APIs. And if your existing code uses deprecated APIs, update that code as soon as possible.
Deprecation of OpenGL and OpenCL

Apps built using OpenGL and OpenCL will continue to run in macOS 10.14, but these legacy technologies are deprecated in macOS 10.14. Games and graphics-intensive apps that use OpenGL should now adopt Metal. Similarly, apps that use OpenCL for computational tasks should now adopt Metal and Metal Performance Shaders.

Metal is designed from the ground up to provide the best access to the modern GPUs on iOS, macOS, and tvOS devices. Metal avoids the overhead inherent in legacy technologies and exposes the latest graphics processing functionality. Unified support for graphics and compute in Metal lets your apps efficiently utilize the latest rendering techniques. For information about developing apps and games using Metal, see the developer documentation for Metal, Metal Performance Shaders, and MetalKit. For information about migrating OpenGL code to Metal, see Mixing Metal and OpenGL Rendering in a View.

https://developer.apple.com/ios/whats-new/#deprecationofopengles

Deprecation of OpenGL ES

Apps built using OpenGL ES will continue to run in iOS 12, but Open GL ES is deprecated in iOS 12. Games and graphics-intensive apps that previously used OpenGL ES should now adopt Metal.

Metal is designed from the ground up to provide the best access to the modern GPUs on iOS, macOS, and tvOS devices. Metal avoids the overhead inherent in legacy technologies and exposes the latest graphics processing functionality. Unified support for graphics and compute in Metal lets your apps efficiently utilize the latest rendering techniques. For information about developing apps and games using Metal, see the developer documentation for Metal, Metal Performance Shaders, and MetalKit.

Steps to reproduce:

Minimal reproduction project:

archived discussion ios macos rendering

Most helpful comment

¯\_(ツ)_/¯

If Apple wants to shoot itself in the foot, so be it. We won't work on Metal support just to accommodate their ambitions of competing with Microsoft as the "we're big enough to have our own proprietary graphics library".

So Godot will issue deprecation warnings on macOS 10.14 and that's just fine.

macOS users can be grateful to Valve and Khronos for obtaining the opensourcing of MoltenVK, so that we can use Vulkan on macOS too. If all goes well we should have Vulkan support before macOS 10.15 comes out with potentially no OpenGL support at all. If not, macOS gamers will have to learn how to dual boot Linux :)

We're working hard to provide good macOS support, but if Apple just keeps breaking compatibility and making sure to only be a second class citizen, we can't fight them. But again, everything should be fineâ„¢ thanks to MoltenVK.

All 23 comments

¯\_(ツ)_/¯

If Apple wants to shoot itself in the foot, so be it. We won't work on Metal support just to accommodate their ambitions of competing with Microsoft as the "we're big enough to have our own proprietary graphics library".

So Godot will issue deprecation warnings on macOS 10.14 and that's just fine.

macOS users can be grateful to Valve and Khronos for obtaining the opensourcing of MoltenVK, so that we can use Vulkan on macOS too. If all goes well we should have Vulkan support before macOS 10.15 comes out with potentially no OpenGL support at all. If not, macOS gamers will have to learn how to dual boot Linux :)

We're working hard to provide good macOS support, but if Apple just keeps breaking compatibility and making sure to only be a second class citizen, we can't fight them. But again, everything should be fineâ„¢ thanks to MoltenVK.

And MoltenVK supports iOS as well thankfully.

I'm starting to question Apple's membership in Khronos.

Carbon has been deprecated for a decade. There are still apps using it today.

I wouldn't consider this anything more than apple saying "we won't fix it if it's broken. and we're now gonna spam console with deprecation warnings no one reads"

there is no way they will actually yank opengl out. FAR too many apps rely upon it.

Bad indeed Blender will be the one to be most badly hit although I don't think that OpenGL will be removed anytime soon but still. Bad.

Although it's not a bad move, as per the theme of Apple to be professional and fast. OpenGL has been buggy and it has surely cause people to look for alternatives. Like Vulkan.
But hopefully because of the port Godot will dodge the bullet.

And finally Blender might start work on Vulkan port after 2.8 possibly sooner.

@MysticalOS don't be too sure of that, Carbon along with any 32bit API are gone in 10.14, parts of the Carbon API have died slow deaths over the past few years. We ran into trouble in 10.9 when Apple finally removed Open Transport.

Though both are good examples of how long Apple will keep deprecated APIs around and I do applaud them for the most part. While Windows is hampered by still attempting to support things from the DOS and Window 1.0 era, Apple will toss things out that have outlived their use.

The question is, has OpenGL outlived its use?

That all said, OpenGL will be around long enough to make a comfy transition to Vulkan and support Metal through MoltenVK and as that was already the plan we'll be fine.

The only worry that I have is that on iOS Apple has been far more willing to chuck out anything they no longer want after 2 or 3 major versions of the OS so we can likely see OpenGL disappear from iOS first.

not sure where you get that 32 bit is gone already in 10.14.

10.14 is still giving deprecation warnings, but 32 bit apps still open in first 10.14 DP

Apple generally warns and nags for a long time before just killing something. eventually yes they'll cut stuff but I believe we'll get a decent warning period first.

iOS does tend to be much faster turnover in getting rid of things though, that's quite true.

OpenGL has been buggy and it has surely cause people to look for alternatives.

Isn't that only because Mac's kept holding on to the ancient 2010yr OGL3.3 instead of updating to modern standards? OpenGL itself didn't seem buggy either but rather their abhorrent driver implementations.

Carbon along with any 32bit API are gone in 10.14

macOS 10.14 still have 32-bit API (but it will be the last macOS release with 32-bit support).
Xcode 10 beta already have no support for compiling 32-bit applications, all OpenGL related tools are still included.

The solution, once we get Vulkan support, is to have MacOS builds use MoltenVK, no?

The solution, once we get Vulkan support, is to have MacOS builds use MoltenVK, no?

That's what I wrote above, yes :)

This announcement doesn't really impact our plans since we wanted to move to Vulkan nevertheless, so by the time Apple does remove OpenGL support, we should have a working Vulkan renderer using MoltenVK on macOS and iOS.

@OvermindDL1 Exactly, Apple's OpenGL drivers are really outdated already and there have been no functional debug tools at all for about 4 years.

@vnen That (iOS being affected) is why I was mildly confused when the blog post on Godot's Vulkan port called macOS and iOS "a platform not used very much."

@akien-mga @karroffel I was dabbling with Vulkan a bit myself, and since there's so little reference code around, I hope you're aware of Robert Konrad's work on https://github.com/Kode/Kha.

@poke1024 Well, in terms of Godot users (which was what the blog post meant) there's only a small percentage exporting games to macOS and iOS. It's quite an investment of time to work on a Metal backend that won't introduce new features, only a minority will benefit, and will have to be maintained over time.

Same applies for DirectX, which is arguably much more useful than Metal, since it works on Windows devices, which is the majority of users, and also can be availed of for UWP, that can run on Xbox One too.

I don't support Apple in any way, but let's be real here. iOS is a huge piece of the mobile market and you can't just deny it. If there aren't a lot of Godot users exporting to iOS then I feel it's more a "ah yes I wanna make a mobile game, Godot sucks at iOS, it's off the table" kinda deal than "nobody needs iOS".

I'm only a hobbyist, and have no knowledge of the industry (and of Godot's users for that matter), but iOS seems like an essential market to me too. Vulkan and MoltenVK is a solid solution though. In many ways, Metal is quite similar to Vulkan, with a bit more handholding in some places, so if Godot gets things right with Vulkan, things should be fine with Metal via MoltenVK too.

The point is not the iOS market. If Godot didn't care about it we could just stop supporting iOS. The point was about making and supporting a renderer backend just for iOS (technically for macOS as well, but still).

The issue with the current iOS export is that there are no fixed maintainers. A lot of people push regular fixes to Windows, Linux, and even Android, but iOS is kinda forgotten (and I do blame Apple a bit for that, because the entry barrier is much bigger than the other platforms). Many people that goes for a free engine don't have the means to acquire the expensive Apple hardware.

Nobody is saying we should "abandon" iOS, it's more like that we need a person or group that adopts the iOS port and keep maintaining it. If we had some people committed to maintain it, even a Metal backend could be considered. This way the core devs could focus on making and fixing the features everyone uses, and port maintainers could fix the platform-specific issues.

In any case, MoltenVK should take care of the current needs. I'm pretty sure reduz will test it on macOS and iOS to make it work.

Yeah I too think that using MoltenVK is going to be a good idea for now. Maintaining a renderer backend is not something very easy to do, even if someone creates one.

@vnen
But I don't think looking for some people who would agree to work on it will be a bad idea, we can just start something off and see if people interested in iOS development would like to help.
There are lots of people who won't do anything unless you ask them to, so we can try.....?

If we are able to do it I don't see why not. Godot has already been getting a lot of attention and with this it might become the engine of choice for the rich devs(meaning more patreons?) who can afford an iOS/Mac device.

Good news everyone.
https://www.phoronix.com/scan.php?page=news_item&px=Zink-Gallium3D-OpenGL-Vulkan
Google + Valve + Mesa community have open an option of a convoluted way to support Opengl on the Mac.

Opengl -> Vulkan -> MoltenVK -> Metal

I would not be surprised if this convoluted pipeline would be faster.

@akien-mga Can you elaborate rules about beating a dead horse topic?

@hungrymonkey Aren't you the one beating a dead horse now commenting on a closed issue where the last comment was 6 weeks ago...?

So, again, Godot 3.2 or 4.0 will have a Vulkan renderer, which will be translated to Metal probably via MoltenVK, unless we decided to oxidize the codebase and use gfx-rs instead.

@akien-mga I just come across at the absurd solutions for supporting Opengl. I just found the news a bit funny.
I did ask about the rules for beating a dead horse. I didn't know if it was clarified. I already knew about the official plans from this thread

Well nobody wants to support OpenGL here, so it's off-topic. Anyway, let's let the horses rest in peace.

Was this page helpful?
0 / 5 - 0 ratings