Live data from Hacker News

Direct3D to OpenGL abstraction layer

github.com

81–90 of 111 posts

Re: Direct3D to OpenGL abstraction layer

#82
post #52

Earlier quoted context omitted.

So far most AAA games are still developed for DirectX only. Those are the games that make or break a platform. Doom 95 was arguably the kind of killer app that established Windows as the primary gaming OS. In the context of Valve's SteamOS strategy it makes perfect sense to encourage more major developers to build games on a portable API like OpenGL or possibly AMD's Mantle by making it as easy as possible. If they f…

sorry if i wasn't clear, but i am aware that most AAA games use DX. the same is not true for open source. there are already DX->GL compatibility layers, although most of them are in house, by companies that produce ports (ala Feral Games). yes, i entirely agree with you.. almost. ideally, i'd like DirectX to.. go away, forever. proprietary APIs that result in lock in to a software or hardware platform are seriously h…

This was probably done to persuade the people complaining about porting their codebase to OpenGL (and hence Linux / SteamOS).

Re: Direct3D to OpenGL abstraction layer

#83
post #55

Earlier quoted context omitted.

> Basically any engine thats runs on PS3/PS4 does like UnrealEngine, Cryengine, idTech, Unity and most indie/open source engines are OpenGL anyway That's completely wrong. PS3 never used OpenGL and PS4 doesn't do either. Unreal while having somewhat working Mac port is usually ported via Cedega and not the Mac version which is largely unmaintained. The Linux port of Unreal was never merged back either. Presently ther…

Quote from Wikipedia >> The current release is Unreal Engine 3, designed for Microsoft's DirectX 9 (for Windows and Xbox 360), DirectX 10 (for Windows Vista) and DirectX 11 (for Windows 7, Windows RT and later); OpenGL (for OS X, Linux, PlayStation 3, Wii U, PlayStation Vita, iOS, Android); Stage 3D (for Adobe Flash Player 11 and later); and JavaScript/WebGL (for HTML5). You are right that CryEngine doesn't use OpenG…

Crytek apparently read your comment ;) and an hour later announced official support for Linux.

http://venturebeat.com/2014/03/11/steamos-gets-a-powerful-ne...

Re: Direct3D to OpenGL abstraction layer

#84
post #7

This is huge, really huge for anyone who write DirectX games and want to make them run on OSX/Linux. This is basically what a part of Wine do, am I wrong?

Wine is a bit different, I'm not 100% sure but it's more like a reimplementation of native calls than anything. But yeah, this is awesome. As a side note, developers who want to make games run on OSX and Linux should just stop targeting DirectX. This is good for already-existing games and port them over, but in 2014 if you're still writing games in DirectX, you're most likely doing it wrong.

If nothing major has changed, I'd rather use the nice API DirectX offers than the general weirdness that is OpenGL. Any project that makes DirectX (as an interface) available for all platforms is great news in my book.

Re: Direct3D to OpenGL abstraction layer

#85

Earlier quoted context omitted.

>>OpenGL is years behind D3D (not DirectX, it's not comparable!) in many areas, Explain please?

Complete lack of multicore rendering. You can practically issue render commands only from one thread. And there is no way to save bunch of commands anymore as display lists were deprecated. Also it's still very much state machine based. So you have to do a lot of individual calls to set everything up for actual draw call. I personally love OpenGL and use it on my work. However this is one of the biggest drawbacks on…

ARB_multi_draw_indirect (and its bindless friends such as NV_shader_buffer_load) somewhat invalidates your statements re: saving a bunch of commands.

Re: Direct3D to OpenGL abstraction layer

#86
post #7

This is huge, really huge for anyone who write DirectX games and want to make them run on OSX/Linux. This is basically what a part of Wine do, am I wrong?

Wine is a bit different, I'm not 100% sure but it's more like a reimplementation of native calls than anything. But yeah, this is awesome. As a side note, developers who want to make games run on OSX and Linux should just stop targeting DirectX. This is good for already-existing games and port them over, but in 2014 if you're still writing games in DirectX, you're most likely doing it wrong.

OpenGL drivers on Windows are still pretty far behind DirectX drivers, especially on the kind of low-spec hardware (read: Intel GPUs) average customers have. If you use OpenGL instead of Direct3D you might be paying as much as a 50% performance penalty (we certainly see about that when comparing our GL and D3D renderers for the same scenes)

Re: Direct3D to OpenGL abstraction layer

#87
post #66

Earlier quoted context omitted.

Complete lack of multicore rendering. You can practically issue render commands only from one thread. And there is no way to save bunch of commands anymore as display lists were deprecated. Also it's still very much state machine based. So you have to do a lot of individual calls to set everything up for actual draw call. I personally love OpenGL and use it on my work. However this is one of the biggest drawbacks on…

No clue what multicore rendering D3D offers, but 'complete lack' is an overstatement. OpenGL has context sharing, which means several contexts in different threads sharing the same objects. You can issue commands as long as you synchronise access to objects yourself. In practice, that means filling buffers, rendering to an off-screen framebuffer, etc. from other threads.

Multithreading in GL does not work consistently. If you ask the driver vendors (AMD, NVIDIA, etc) they will tell you it doesn't work at all or across platforms. If you ask engine developers (like Valve) they will tell you in talks that it doesn't work across platforms.

Re: Direct3D to OpenGL abstraction layer

#88

Earlier quoted context omitted.

>>OpenGL is years behind D3D (not DirectX, it's not comparable!) in many areas, Explain please?

I think it's not years behind, for example the latest AAA game I've played on OSX (Elder Scrolls Online) run natively on it, and it's in OpenGL. It look as good as on PC where it run with D3D.

The gap between GL and D3D has nothing to do with visual quality and everything to do with framerate and load times.

Re: Direct3D to OpenGL abstraction layer

#89
post #44

Earlier quoted context omitted.

You still have to write an absurd amount of spaghetti code around testing GL extensions that are available. Especially when you consider the Intel IGPUs from the last 5 years - the first gen is only 2.1, second gen 3.1, and Ivy Bridge and above is 4.3. But besides those the Nvidia / AMD parts have supported 3.3 and above since 2006. Of course, if you are targeting Windows XP... you got to think back a lot further tha…

That's true if you want to support older OGL versions. Personally I use the ES3 subset of 4.3 right now. Same code works perfectly on ES3 mobile HW and 4.3 desktop HW. The only features it lacks are geometry and tesselation shaders. I'm also using compute shaders right now, even though they are not supported in ES3 they are going to be supported in the ES next update. And that gives me effectively everything geometry…

> The only features it lacks are geometry and tesselation shaders.

fp64, draw_indirect, multi_draw_indirect, shader_buffer_load, bindless_texture.

These are all killer features in writing fast renderers.

Re: Direct3D to OpenGL abstraction layer

#90
post #81
post #79

Earlier quoted context omitted.

But then add Glide (DOS), please. :-)

I left it out on purpose, because DOS was a Microsoft platform as well.

> I left it out on purpose, because DOS was a Microsoft platform as well.

MS-DOS was a Microsoft platform, but not DOS itself:

> http://en.wikipedia.org/wiki/DR-DOS

Also Glide was not a Microsoft API.

Post reply on HN