Click to See Complete Forum and Search --> : SDL game engine
hawkagent
June 12th, 2007, 05:26 AM
Hi,
I'm trying to learn c++ with the goal able to program 2D games like pacman and stuff like mario bros and final fantasy I. Although C++ is new to me, I have done several other object oriented programming languages, like java. However, I never programmed games before.
I read an article about game programming, saying that I need a game engine, it recommended SDL (http://www.libsdl.org/).
When I looked up for some demo's of SDL, I didn't like the program going full screen all the time. Does anyone know if it's possible to make stuff run in a windowed mode with this engine? Also, is this a good game engine to start with and will I need more advanced engine later on?
ne0n82
June 12th, 2007, 05:22 PM
yes it is possible to make SDL programs to run in either fullscreen or windowed mode, but SDL itself isnt a game engine its am API framework like directx. if your looking for a "game engine" i think the torque engine can be licenses for only $99 maybe even less now, its a little old but not ancient and for that price you cant beat it, and you can also download a limited license to be able to use it for free as long as your not producing commercial games, so its free for education games
IllegalCharacter
June 17th, 2007, 11:19 PM
If you don't want the window to go fullscreen, don't put SDL_FULLSCREEN in your SDL_SetVideoMode call.
Like ne0n82 said, SDL is not a game engine. It is simply a cross-platform library that functions like DirectX/Win32 API (minus the 3D graphics capabilities and MUCH less annoying), allowing you to have low-level access to video/input/sound hardware and create basic windows. For simple games like Pac-Man, SDL should work just fine. If you want some more sophisticated graphics engines, Crystal Space (http://www.crystalspace3d.org/main/Main_Page) or Ogre 3D (http://www.ogre3d.org/) are free ones, however they require a lot of C++ and Object-Oriented theory as they work off things like Factory Patterns and things like that. At least Crystal Space does, I haven't done much with Ogre.
Before you get into game programming, I would recommend that you have a very good understanding of C++, STL (Standard Template Library) and possibly the Boost (http://www.boost.org/) libraries as this will make your life much easier. You also want to understand memory management, as C++ doesn't manage memory like Java does (look at things like memory leaks, dangling pointers, memory fragmentation, etc.). The gaming libraries will probably handle a lot of this for you, but it is important to know about so that you don't accidentally make mistakes.
Three276Seven
June 26th, 2007, 10:56 PM
I worked with SDL. This is after I had a good amount of DirectX under my belt. I quickly returned to DirectX because, plainly put, of the lack of features. For instance: it is nye impossible (atleast what I have seen) to rotate a texture in SDL. In DirectX it is extremely easy. Like IllegalChar said: SDL is much less annoying but once you get the hang of it(directx) I think you can go much further with it(directx) than with SDL. That's my two cents.
Edit: typo
IllegalCharacter
June 27th, 2007, 07:29 PM
DirectX is much more feature-full (is that a word?) than SDL. However when you combine OpenGL with SDL it adds much more functionality. The two pretty much tie together seamlessly, all you have to do is put SDL_OPENGL when you create your SDL window and your OpenGL calls will display in that window.
codeguru.com
Copyright Internet.com Inc., All Rights Reserved.