14 ms·
Metal – Apple’s new graphics API
- corysama 12y agoAny mention of hardware requirements? I'm betting this is 5s/Air-only. But, I'd love to be wrong.
- hraedon 12y agoA7 and above, if the keynote is correct.
- yaeger 12y agoIsn't this part of the new iOS8? If so, I think I recall seeing the screen which models are eligible and I think the 4S was the first on the screen. Going up all the way to the 5S. So, I think everything before and including the iPhone 4 will be left out?
- pjmlp 12y agoSo OpenGL seems to loose support on the platform that helped to make it relevant again.
- coldcode 12y agoThis to me is more surprising than Swift. But it will make for difficult platform decisions. But since there are 4 game platforms already working on it (Unreal hasn't committed) maybe it's not a bad idea at all.
- unphasable 12y agoI thought Unreal was 1st in line? Why would the be on stage as the poster child for Metal yet not commit?
- mikewhy 12y agofirst was Unity, Unreal wasn't mentioned but Epic Games were.
- CanSpice 12y agoEpic Games makes the Unreal Engine.
- unphasable 12y agogood news: http://i.imgur.com/ke0czgU.png http://i.imgur.com/ke0czgU.png
- coldcode 12y agoAh, so much stuff went by I missed the name.
- __david__ 12y agoThe big graphical demo was Unreal Engine 4 on iPad...
- mikewhy 12y agoSorry everybody, I was thinking of the slide of engines / companies[1]. I am aware Epic makes the Unreal Engine, but wasn't aware that the Zen Garden on Metal demo was intact UE4. [1]: http://ww4.sinaimg.cn/large/7677825ftw1eh0chc9b00j20sg0iyq57.jpg http://ww4.sinaimg.cn/large/7677825ftw1eh0chc9b00j20sg0iyq57...
- klodolph 12y agoAnything that provides access to GPU command queues is welcome. It's been clear for a while that OpenGL and D3D are ill-suited to modern ways about thinking about GPUs. This also explicitly supports multithreaded clients, each with their own command queues. https://developer.apple.com/library/prerelease/ios/documentation/Miscellaneous/Conceptual/MTLProgGuide/Cmd-Submiss/Cmd-Submiss.html#//apple_ref/doc/uid/TP40014221-CH3-SW1 https://developer.apple.com/library/prerelease/ios/documenta... The shading language appears to be precompiled (which is sorely missing from OpenGL) and based somewhat on C++11. https://developer.apple.com/library/prerelease/ios/documentation/Metal/Reference/MetalShadingLanguageGuide/Introduction/Introduction.html#//apple_ref/doc/uid/TP40014364 https://developer.apple.com/library/prerelease/ios/documenta... My concern is drivers: drivers for video cards on OS X haven't been as good as Windows drivers. That, and of course the specter of another platform-specific API. This invites a comparison with Mantle. I don't think either Metal or Mantle will "win", but they're good prototypes for the next generation of GPU APIs.
- apetresc 12y agoAs far as I know, Metal has only been discussed for iOS. Did I miss an OS X announcement somewhere? Otherwise, the driver point is moot.
- rm445 12y agoI'm daring to post from a position of ignorance, trusting intuition to be correct. But this is a framework for shipping (graphical and other) workloads over to the GPU. Surely it isn't mobile-only? Just for instance, Apple sell an extremely expensive workstation with two very powerful graphics cards. Providing better ways to use a Mac Pro's GPUs is a good way to sell more Mac Pros, and a way to unlock more computational power as the power of CPU cores has levelled off.
- cwyers 12y agoThe name "Metal" gives a hint, though -- the API provides better performance by getting you closer to the metal. The metal in the A7 is different than the metal in those Mac Pros.
- higherpurpose 12y agoYou can thank AMD for this one. This is exactly why I supported Mantle initially - not necessarily because I thought Mantle will replace DirectX and OpenGL, but because it would push all the others to adopt similar changes to their APIs. And this is exactly what happened, first OpenGL (through AMD's extension for now at least), then Microsoft with DirectX 12 [1], and now Apple, too. Before you get too excited, though, remember Mantle "only" improved the overall performance of Battlefield 4 by about 50%. It can probably get better than that, but don't expect "10x" improvement or anything close to it. [1] - http://semiaccurate.com/2014/03/18/microsoft-adopts-mantle-calls-dx12/ http://semiaccurate.com/2014/03/18/microsoft-adopts-mantle-c... http://hothardware.com/News/New-Reports-Claim-Microsofts-DirectX-Rips-Off-Mantle-Wont-Help-Xbox-One--But-Is-It-True-/ http://hothardware.com/News/New-Reports-Claim-Microsofts-Dir...
- akamaka 12y agoThe 10x improvement that Apple claims is presumably rooted in Mantle's design. The Mantle docs also claim an order of magnitude improvement in draw calls. See the "Small Batch Problem" section in this PDF: http://www.amd.com/Documents/Mantle_White_Paper.pdf http://www.amd.com/Documents/Mantle_White_Paper.pdf
- danudey 12y agoFrom what I understand, it's more accurate to say that it reduces CPU use by about 50% (rather than improving performance). If CPU is not your bottleneck, you won't see a performance improvement. If it is (which is common these days), then you'll have twice as many free CPU cycles on your main thread, which will translate into however much improvement your GPU can muster.
- sliverstorm 12y agoEven if CPU isn't the bottleneck, you ought to see some power savings. Either way, it will make it easier to bolt a monster GPU onto a smaller, more efficient CPU. (What we do about GPU power consumption is a different problem...)
- MaxBarraclough 12y ago
- syjer 12y agoThis one is quite surprising. I would have guessed that given the pervasive use of opengl(es) in their os, they would have advanced a azdo approach ( as described in http://www.slideshare.net/CassEveritt/approaching-zero-driver-overhead http://www.slideshare.net/CassEveritt/approaching-zero-drive... ).
- kevingadd 12y agoThe 'fill command buffers with commands' approach they adopted is basically an alternate way of achieving the same goals as AZDO. You can view AZDO GL as just filling a command buffer for you behind the scenes (with a few other quirks)
- general_failure 12y agoDoes this mean now that xplatform graphics code will be a thing of the past?
- deminature 12y agoOpen GL ES is not going away, just a more performant option is available. Also, Metal is supported by at least two of the most popular engines (Unity and UE4), so they should handle most of the cross-platform work, provided you are using one of those.
- jarrett 12y agoIt's somewhat scary to see new graphics APIs being introduced. The fragmentation of OpenGL is enough of a headache, but at least it offers some semblance of "write once, run anywhere." The introduction of Mantle and Metal, plus the longstanding existence of Direct3d, makes me worry that OpenGL will get no love. And then we'll have to write our graphics code, three, four, or goodness knows how many times. I know: It's not realistic to expect "write once, run anywhere" for any app that pushes the capabilities of the GPU. But what about devs like me (of whom there are many) that aren't trying to achieve AAA graphics, but just want the very basics? For us, "write once, run anywhere" is very attractive and should be possible. I can do everything I want with GL 2.1, I don't need to push a massive number of polys, I don't need a huge textures, and I don't need advanced lighting.
- ndesaulniers 12y agoIn that case, you should be happy that WebGL will be on by default in iOS 8 and Safari.
- jarrett 12y agoVery happy indeed!
- general_failure 12y agoWhere did you read that uiwebview/mobile safari in ios8 has webgl?
- jasoncartwright 12y agohttp://www.extremetech.com/computing/183421-apple-wwdc-keynote-watch-the-live-video-unveil-of-ios-8-and-os-x-10-10-live-blog http://www.extremetech.com/computing/183421-apple-wwdc-keyno... - search for WebGL
- stevejohnson 12y agoThat's for desktop Safari.
- shmerl 12y agoKey questions: 1. Is it open and cross platform? 2. Is it going to be supported across all GPU vendors? If either of those is no, than it's a failure from the start and just another walled garden thing.
- jkrems 12y agoThe whole point is to be closer to the "metal". Doing that across GPU vendors would be, well, OpenGL. It's the same as the native interfaces for the PS4 and other consoles - it's supposed to be platform/GPU specific. There's a limit to how much performance a general purpose graphics abstraction can enable.
- foxhill 12y ago> There's a limit to how much performance a general purpose graphics abstraction can enable. that remains to be seen, especially given how similar all the GPUs are today. if it weren't for the longs peak shambles, we might not need Mantle/Metal.
- MaxBarraclough 12y ago> if it weren't for the longs peak shambles, we might not need Mantle/Metal. Given than Mantle is being used in AMD/Windows (in preference to Direct3D - no OpenGL to be seen) it doesn't seem fair to blame only OpenGL.
- foxhill 12y agoDirectX has it's own problems.
- toksaitov 12y agoI think we all know the answers from day 1
- to3m 12y agoBeing "another walled garden thing" will hardly be its death knell. Proprietary single-vendor APIs are already common on games consoles, and it hardly seems to have caused a problem. Look at DirectX, even; not quite single-GPU-vendor, but hardly renowned for its portability, and popular nonetheless. These things will succeed if the platform is popular, and other factors are pretty irrelevant. I suspect iOS is popular enough to make this work.
- toksaitov 12y agoJudging by what we have it looks usable not only for graphics. Finally we got OpenCL on iOS. Kind of
- vacri 12y agoAnother framework, another needlessly generic word to play havoc with search.
- ausjke 12y agoSaw lots of HN news on Apple, I own absolutely no Apple devices, as I think while them are well made, the software ecosystem coming with it is similar to whatever Microsoft had before, i.e. essentially closed, and that is important to me, it made me to own zero Apple devices. Am I alone here? I'm running Linux everywhere from home to my office for years, and my tablet/cellphone is Android-based.
- tvon 12y agoYou are not alone but you are probably in the minority. (quick edit: You saw a lot of Apple news because the WWDC keynote was today)
- ausjke 12y agofor what reason that my comment as above deserves down-votes? could those down-voters explain why this should be down-voted? you have down-vote rights does not mean you can abuse it, shame on you HN
- bobbles 12y agoYou're getting downvoted because your comments add nothing to the discussion and have nothing to do with the article that has been posted.
- sbuk 12y agoYou are attempting to hijack a thread about Apple's new Graphics API, Metal. I downvoted you for this and because your post adds nothing to the discussion.
- endgame 12y agoYou are definitely not alone. I'll probably take the rest of the week off from HN until they get over the fact that iOS apps now have IPC.
- sbuk 12y ago
- pekk 12y agoYet another special Apple-only lockin mechanism.
- vincetogo 12y agoI really don't see this being the case. Any competently designed graphics engine has an abstraction layer between the app's graphics routines end the platform's graphics API. While it's not trivial, another API shouldn't be something that prevents an app from being ported to other platforms.
- kirab 12y agoDid you completely miss just how much DirectX locked games into the Windows platform?
- pjmlp 12y agoYou mean the same that were equally available on Wii, PS 3 and XBox 360?
- MaxBarraclough 12y agoThere's a bit more to it than that, though. There wasn't much of a a perceived interest in gaming on the Mac and Linux platforms. The Mac and Linux graphics drivers were awful. A vicious cycle, which we're (hopefully) seeing start to break now. Mac is supported by at least some major games, which is a step forward. The Steam box should speed things along nicely for Linux, hopefully. As pjmlp points out, games were successfully ported to different consoles, it's just that Mac and Linux weren't seen as worthwhile targets. I suspect porting a Windows game to PS3 would be much harder than porting to Mac, but developers managed.
- abdophoto 12y agoThis has to be a move towards the development of games on an Apple TV.
- hjnilsson 12y agoIndeed, it also explains why they put the A7 in all their devices (instead of recycling the A6 as they did previous years). An Apple TV with A7 and Metal will be competitive with Xbox360 / PS3 / Wii U spec-wise. And without a fan!
- orkoden 12y agoCurrently Apple TV has an A5. The A8 is due in the fall. So an updated Apple TV with an A8 could be a powerful gaming machine.
- chrismorgan 12y agoI hate pages that deliberately break the functionality of the Space bar.
- deleted 12y ago[deleted]
- chrismorgan 12y agoDownvotes!? Why? The Space bar is supposed to let me scroll, and on the linked page it doesn’t do anything.
- oneofthose 12y agoThis seems to be Apple's answer to Google's RenderScript. It is too bad big companies (Google, Apple) are developing their own GPU software stack instead of building upon and furthering existing frameworks such as OpenCL. OpenCL desperately needs a kick in order to catch up with CUDA. Instead they are focusing on things like SyCL, hoping to catch up with already superior projects such as C++AMP. OpenCl should rather fix their poor specification and get implementers on the same page about it. The mobile community could have been a driving force. Instead, frustrated with what OpenCL is, mobile decided to roll their own. As always.
- pjmlp 12y agoMetal is for graphics programming, not GPGPU. But yes, OpenCL with its basic C API is way behind what CUDA offers in terms of language support. Maybe SPIR will fix it, but it remains to be seen if anyone on HPC will care.
- oneofthose 12y agoI disagree. "The Metal framework supports GPU-accelerated advanced 3D graphics rendering and data-parallel computation workloads".
- foxhill 12y ago> But yes, OpenCL with its basic C API is way behind what CUDA offers in terms of language support. strange, language support is really the only thing that CUDA doesn't have over OpenCL. there are C++ (and python, Java, various others) bindings for host code, at least. if you're looking to use device intrinsics in your kernel code (at the cost of portability) then blame nvidia for not exposing it (and for their lack of support for OpenCL in general). > Maybe SPIR will fix it, but it remains to be seen if anyone on HPC will care. yes, there are people doing HPC that care.
- pjmlp 12y agoSo where are those Fortran and C++ compilers for OpenCL kernel code?