GLBasic forum

Feature request => 2D => Topic started by: doimus on 2009-Jul-13

Title: DirectX support?
Post by: doimus on 2009-Jul-13
Is there any chance of GLBasic supporting DirectX API anytime soon?

Not that I prefer it over Open GL (on contrary, I actually prefer OGL) but I am in the position to suggest GLB as framework for development of casual PC games. The only thing that prevents GLB from being ideal casual framework is lack of support for DirectX. And no, I do not think of DX9 with shaders 3.0 - I'm talking about basic DirectX support, like DX7.

Some discussion we had in PSP thread made me think about GLB and casual games market.
At the moment most if not all casual portals do not accept games which aren't DirectX compatible. There are multiple reasons for that and most prominent is that many Windows installations run on default Microsoft graphics drivers, which have horrible OpenGL support.

It would be nice if we had some kind of DirectX wrapper for GLB. Even the most basic, 2D only, DX7 support. Somethin like what BlitzMax does - runs on OpenGL, but reverts back to DX7 on Windows.

Yes, I know that DX sucks, but anyway....
Title: Re: DirectX support?
Post by: Hemlos on 2009-Jul-13
GLBasic supporting DirectX API

You cant mix opengl with directx typically.
Title: Re: DirectX support?
Post by: Kitty Hello on 2009-Jul-13
The problem with DX is, that you have to rewrite and rewrite and rewrite your code with every single version the provide. It's such a pain.
I might consider writing a wrapper, but not #1 priority.
Someone has made a Xors wrapper, though.
Title: Re: DirectX support?
Post by: doimus on 2009-Jul-13
I haven't yet met a programmer who likes Directx.  =D

And I'm fully aware of Microsoft's policies and destruction of backwards compatibility in newer versions.

What I'm proposing is just DX wrapper with basic functions, just as a fallback, idiot-proof platform on Windows.
I don't know what GLB does when OpenGL drivers are missing. It reverts to software? But I guess the performance of software rendering would be bad on higher resolutions, right?

Some kind of basic DX support would be great, just for those cases.

But of course, take your time with it. No hurries whatsoever.