DirectX or OpenGL - 2D

Started by
4 comments, last by frob 8 years, 8 months ago

Okay so I would like to create a 2D game but I don't know if DirectX or OpenGL is better for 2D.

Does anyone have any experience they could share?

Advertisement

Neither is necessarily "better" for 2D. They are both designed for 3D, and they are both also suitable for 2D.

Have you already considered SDL or SFML?

I'm going to quote fastcall22 on this one from the previous topic:

This sounds familiar...

Nope nope nope.

devstropo.blogspot.com - Random stuff about my gamedev hobby

In one sense it doesn't really matter because 2D is just a special-case of 3D.

In the old days both APIs had specific 2D pipelines but they're all deprecated (or just outright removed) in the modern versions of the APIs so you'll be using the same kind of setup and draw calls for 2D as you would use for 3D.

The exception to this is if you use a wrapper library explicitly designed around 2D drawing, but then you're not really using either API at all and your question is more one of which wrapper library is best.

Direct3D has need of instancing, but we do not. We have plenty of glVertexAttrib calls.

Thanks servant i'll look into SDL and SFML.

Please use the search button. There are thousands of this topic already, we don't need another.

This topic is closed to new replies.

Advertisement