13 ms·
Carmack: Direct3D is now better than OpenGL
- malkia 16y agoCall of Duty does not use OpenGL. Poor journalism. It's so simple - take depends.exe and run it on the executable, or use procexp, then Ctrl+D and see what DLL's are being used. Even more simpler - look at the Redist folder - it has DirectX in it. I'm not really taking sides here - for my personal projects I use OpenGL, and find it easier to use (especially from Common Lisp, Lua, JavaScript), also it has structure that I like better.
- bhrgunatha 16y agoInteresting that he says OpenGL has been more concerned with backwards compatibility than Microsoft has with Direct3D which is surprising considering Microsoft's normal compatibility fanaticism.
- ajross 16y agoOpenGL did this via a fork, basically. The standard you really want to be looking at is OpenGL ES v2, which throws out almost all of the legacy stuff (begin/end, fixed function pipeline) in favor of a shader-only architecture which is much cleaner both for application and driver writers. Unfortunately its name says "embedded", but it's very much the future of the standard.
- timthorn 16y agoNot really; Microsoft wants existing software to run on the next version of their OS, and that's still supported. The issue is of source compatibility, I think.
- th0ma5 16y agoit may well be accepted in the gaming market that the cutting edge may break compatibility
- awj 16y agoThis is api-level backwards compatibility for a library that is bundled with the games. Microsoft is fanatical about BC when the alternative is to break a piece of software. When the only people they're inconveniencing are developers, the philosophy changes. And rightly so, otherwise it's just that much harder to build new features.
- stonemetal 16y agoI think you are misinterpreting what he is saying. Direct3D is built on COM so the DirectX 1.0 COM interface still exists and code written against it should still work. However Microsoft has tried to make each version of the API internally consistent and as good as possible, so new versions of the API don't keep legacy junk sitting around. OpenGL on the other hand has made sure that OpenGL1.0 code is still valid in current OpenGL(Pallet swapping FTW). Though I find it a bit odd that he is making that comment now. OpenGL 3.0(back in 2008) started the transition to a modern API. It deprecated the cruft and started building for the future. OpenGL 4.0 was released a year ago with all the deprecated stuff removed, and is now a nice clean API that is actually pretty close to DX.
- recoiledsnake 16y agoI remember the brouhaha when it happened. http://www.gamedev.net/topic/504547-opengl30-i-mean-22/page__PageSize__25__WhichPage__1 http://www.gamedev.net/topic/504547-opengl30-i-mean-22/page_... http://developers.slashdot.org/story/08/08/11/2135259/OpenGL-30-Released-Developers-Furious http://developers.slashdot.org/story/08/08/11/2135259/OpenGL... One of the posts in the first link. >So let me get this straight... In order to allow what, a small handful of old CAD apps to compile against 3.0, they're willing to practically kill off all new applications developed against the API? That makes sense. One customer a year ago is better than ten next week... [grin] >Or maybe they've just realized that a) they've lost everything on Windows to DirectX so it doesn't really matter what they do there, and b) since they don't have a single competing API on other platforms, they don't actually need to make an effort there either. >End result, they can screw over developers as much as they like, and it won't actually hurt them. Windows developers wouldn't have used OGL in the first place, and everyone else will keep using them because there are no alternatives.
- Zak 16y agoI find it odd that there was no mention of working on multiple platforms as an advantage of using OpenGL. I've bought a game or three I wouldn't have otherwise because they offered a Linux version, and I suspect I'm not the only one.
- melling 16y agoYes, Java definitely has an advantage over C# because it's multi-platform. Granted C# really has done a great job of adding nice features that I wish were in Java... This kind of story seems to happen when committees are involved, and there is an overarching need for backwards compatibility. Closures in Java arrive in 2012. 2013 at the latest.
- icey 16y agoWhat platform does Java run on that C# doesn't? Perhaps you meant to say that DirectX isn't multi-platform?
- melling 16y agoMono does give you the ability to run C# code everywhere. So, correct, it's not the language itself that's preventing you to write C# once, run everywhere. Perhaps you understood where I was going in the first place? Anyway, people choose Java because they can write once and deploy everywhere. If you write in the C# .Net ecosystem on Windows, it won't run everywhere, which is fine if Windows is your only target.
- icey 16y agoI don't understand where you're going, no. I write C# on Windows and deploy to Linux and Mac pretty regularly. I know someone who writes C# on Windows and deploys to Arduino. C# seems to be roughly as portable as Java does to me these days. I'm sure I could be wrong, which is why I'm asking which places you can run Java that you can't run C#. Yes, you can write non-portable C# code, but you can write non-portable code in every language.
- zdw 16y agoMulti-platform support is key - for example, where's Direct3D for Android and iOS? All the viable gaming platforms, other than the Xbox 360, are running some OpenGL variant. PC gaming is dying the slow death of piracy and activation - while games can perform better (aren't held back by 5 year old console/mobile hardware), and have better input (keyboard + mouse for FPS), the game vendors can't make as much money on them. That said, Microsoft did push the envelope on this - they weren't held back by the committee model like OpenGL is.
- pmjordan 16y agoAll the viable gaming platforms, other than the Xbox 360, are running some OpenGL variant. That's pushing it a little. Maybe you mean "viable for low-budget, independent developers" (no expensive devkit needed)? It's not that widespread on consoles: Nintendo still seem to be doing well, and none of their platforms support anything close to OpenGL. I'm aware that there is an OpenGL ES implementation for the PS3, but I'd be surprised if that was the only way or even the preferred method of talking to the graphics chip. In my experience, game console graphics programming is usually super low level, with the "API" consisting of a bunch of inline C functions and enum constants for twiddling GPU hardware registers, filling DMA buffers and handling interrupts. Graphics APIs serve 2 purposes: 1. hardware and OS independence (consistent API for the same OS running on different GPU hardware, or for porting software between OSes) 2. sandboxing apps to prevent direct hardware access. The latter is useful for any multitasking platform, whether it's explicitly multi-tasking or just to shield the foreground app from accessing stuff running in the background, like on older iOS versions. If you care about neither, or the latter is taken care of in hardware (IOMMU), then raw access to the GPU lets you do stuff that's way cooler than you could do with a driver and an API (though it's usually more work).
- TillE 16y ago> low-budget, independent developers Well sure, if you're a AAA studio developing bleeding-edge Xbox360/PS3/PC games that squeeze every drop of performance from the GPU (Carmack's area of expertise), your technical choices are going to be very different from those who are developing less graphically-intensive games for iOS/Android/PC/Mac. I suspect the latter group is better represented on HN. And for those, OpenGL ES is almost certainly the best choice.
- jessedhillon 16y ago5-10 years ago this headline would have been more likely to appear on April 1, as John Carmack used to be a member of the OpenGL architecture review board.
- PassTheAmmo 16y agoYes, but already in 2007 his position had changed quite a bit. From http://en.wikipedia.org/wiki/Comparison_of_OpenGL_and_Direct3D http://en.wikipedia.org/wiki/Comparison_of_OpenGL_and_Direct...: In January 2007, John Carmack said that "…DX9 is really quite a good API level. Even with the D3D side of things, where I know I have a long history of people thinking I'm antagonistic against it. Microsoft has done a very, very good job of sensibly evolving it at each step—they're not worried about breaking backwards compatibility—and it's a pretty clean API. I especially like the work I'm doing on the 360, and it's probably the best graphics API as far as a sensibly designed thing that I've worked with."
- rch 16y agoThere are some interesting things happening in the graphics space, driven mainly by low-power/mobile device proliferation. It would be a good time to invent something that changes how real-time rendering happens altogether.
- rbanffy 16y agoIt certainly is if all you want to target is Microsoft platforms.
- drawkbox 16y agoid software Rage HD and engine would now have been as easy to port to iOS if it wasn't for OpenGL. Maybe technologically DirectX is ahead but platform support and inclusion is the reason it is not winning on mobile. Also WebGL is coming and OpenGL ES 2.0 for mobile and web will be a very similar platform. Where is DirectX for the web and mobile in that aspect? And why doesn't Carmack try to port Rage to WIndows Phone...
- Strom 16y agoCarmack said that a port of Rage to WP7 is unlikely due to its lack of support for native code. It's .NET only for now.
- drawkbox 16y agoExactly, what I was trying to get at is OpenGL ES is winning on mobile. DirectX really has no answer and even Windows Devices right now are pretty much XNA/.NET/Silverlight locked as you say no native. Android has the NDK now (year or so ago) because iOS SDK was native and allowed for the performance needed. If Carmack only built in DirectX which is so much farther ahead, he wouldn't be on mobile. OpenGL is much different after 2006 when Khronos took over.
- andrewf 16y agoThere's obviously some shared art assets and toolchain, but it doesn't sound like the actual rendering code in iOS Rage has much, if anything, in common with Rage proper: http://bethblog.com/index.php/2010/10/29/john-carmack-discusses-rage-on-iphoneipadipod-touch/ http://bethblog.com/index.php/2010/10/29/john-carmack-discus...
- alttab 16y agoWhen he eventually does make the switch, it will be awesome. And unlike DNF, he ships games.