2D graphics techniques

Started by
1 comment, last by Dr_Asik 14 years, 5 months ago
I'm thinking about making a remake of some old arcade game, but with some fancy visual effects. Something along the lines of XBLA Space Invaders:
I want to do it in C++ but I never did a game before with that language and I'm kind of lost as to what technologies to use and stuff. (I did some 2d games in XNA before) Should I make the game 3d or 2d? SDL, SDL + OpenGL, plain OpenGL, D3D, others? I've used GLUT for school assignments, is it viable for a real game? Also, any pointers on how to achieve nice particle effects or lighting effects in a 2d game like that? Keep in mind I'm not an artist so drawing isn't my type of thing. That's a lot of questions but hopefully you guys can give me some insight. Thanks.
Advertisement
You've got a few options when it comes down to a classic remake like that (awesome idea, btw).

SDL is a great option especially with the new 1.3 coming through the works (I have a developer pre-beta build and it generally works but there are some issues that still need to be resolved). SDL has a lot of great options for you by handling a lot of the low-level stuff for you but if you want really fast graphics like those in the video you're really going to need to use OpenGL. You don't really need GLUT, just what SDL provides for you. Keep in mind that SDL really only initializes OpenGL for you -- you'll have to learn how to work with OpenGL and do it that way. SDL 1.3 makes that a lot easier but regardless, you'll want that hardware acceleration to make it fast enough to be playable at higher resolutions.

There are other API's available I'm sure but if you want to keep it portable (i.e., running on more than just Microsoft systems), you'll need to use a portable graphics API like OpenGL, SDL, etc.

How proficient are you with C++? If you've never coded anything with it at all before than you're better off using a different language that you're more familiar with. If you really insist on using C++, expect to be learning it for at least 6 months before you can do anything serious with it and up to a year before you become proficient. The syntax is easy to understand -- it's the pitfalls that'll kill you along the way.

Particle effects are, for the most part, easy but they involve a lot of math. C++ makes it easy to handle lots of objects like that using STL containers (in particular vector's) but ultimately you're going to be dealing with a lot of math. I'm sure there are particle system API's out there but so far I haven't seen any that were worthwhile (for 2D applications anyway).

Lighting effects... that depends on what kind of lighting you want. OpenGL will make this very very easy. If you're going for a pure 2D approach, again, expect to be dealing with a lot of math. I know of several tech demos that use SDL to produce some pretty neat effects but it all boils down to what you're thinking of.

If you stick with a classic remake, artwork shouldn't be an issue. All you really need to do is keep the game true to itself while at the same time providing a new and refreshing experience (I refer to that video again).

Good luck! You can chat with me one on one if you'd like. Send me a PM or get in touch with me via AIM/YIM/MSN.

-Lead developer for OutpostHD

http://www.lairworks.com

Thanks a lot for the reply. I think I'll go with SFML (http://www.sfml-dev.org/index.php) as it looks damn nice. I don't want a pure 2D approach, as that's a rather uncommon approach and I want to get experience working with 3D hardware lighting and maybe shaders, particles, etc.

I worked professionally with C++ for a while so I know the language very well, just haven't done any games with it. I do know some basics with OpenGL, primitives, lights, materials, etc, but it's all theory to me at this point.

I think, the first step I'll do is to make pure remake (same graphics, sounds, etc.) just to get familiar with how to make a game with SFML. In XNA, the platform does almost everything for you so there are some things I need to get up to speed working with a lower-level library. Later I'll try putting higher-res graphics, maybe a 3d environment, and maybe some particle effects.

(Nice project you got going there btw.)

This topic is closed to new replies.

Advertisement