We have an old cross platform project that’s using OpenGL. The client is wondering what’s going to happen with the next macOS since they’re deprecating OpenGL. I’m assuming this will totally hose any Xojo apps that use OpenGL? Is there a replacement in the Xojo ecosystem?
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.
Edit: Source - https://developer.apple.com/macos/whats-new/
Right, but if it’s anything like their deprecation of QuickTime it means by February it’ll be gone.
Build your own OpenGL libraries from Mesa and give a stiff middle finger to Apple.
Just because THEY don’t provide it doesn’t mean that it won’t work. Just look at Java.
tl;dr: should work in Mojave, but you have been warned, don’t expect it to work in the next version, or if it does expect bugs that may or may not get fixed.
The lead-in time to this deprecation was incredibly long; according to some reports, Apple hadn’t updated the version of OpenGL since 2010 (yes 2010).
I only got my OpenGL based application working in 2016, after years of on/off trying. High Sierra forced me to delay because of some of the issues. Every minor update (not necessarily bug fixes), cause a blip in error reports from users of High Sierra.
Last year I started work on my first Metal application and while it’s still not available to the public yet, it does run better on High Sierra and Mojave than the OpenGL version, to the point, that it running on a 2015 MacBook (yes the crappiest version) can actually outperform a 2012 Retina MacBook Pro.
However; Metal is only for the macOS, so adopting it, rules out the use on Windows or Linux. You can’t currently use it to it’s full capacity with Xojo, because Xojo still link to macOS 10.9, I was lucky in that I was able to get what I wanted from Metal with very limited code (I am using Metal as a Core Image renderer).
Feedback case for Xojo to use a newer SDK so that we can link to Metal <https://xojo.com/issue/48376> THe report also includes my figures, showing the improvement of Metal v.s. Metal 2 on the two different machines.
If client is looking for x-plat, you may want to consider investigating something like Unity or even WebGL??, if the client wants macOS only, then I’d recommend investigating Metal.
[quote=397732:@Tim Jones]Build your own OpenGL libraries from Mesa and give a stiff middle finger to Apple.
Just because THEY don’t provide it doesn’t mean that it won’t work. Just look at Java.[/quote]
Have you actually done this or is a “I think” it will work response?
I’ve not done it on macOS, but I have on Solaris and Linux. However, now that I look at the environment, it seems that required dependencies are no longer part of macOS. So, I guess the one’s getting the middle finger are Mac developers that depend on OpenGL.
This does not mean that it CAN’T be done, just that it won’t be as easy as ./configure && make.
After all, we don’t need OpenGL on iOS …