SDL Open Source Game

Pages: 123
Well, SFML is a C++ API. It does have C bindings but... I would suggest you just keep going with SDL. It's probably not worth your while to convert 830 lines of code and learn a new library.
closed account (y8h7M4Gy)
hmmm... I'd rather just go with SFML right now instead of regretting it at the end of the summer...
I know it will be hard but I'm pretty familiar with C++ as well as C ( actually I'm better with C++ ) so yeah..
closed account (S6k9GNh0)
I would say the only bad part about SFML is that it doesn't give you the option of using exceptions. Everything else is pretty awesome and, in my opinion, overtakes SDL in many views and conveniences.

I can help you out but I'm about to get really busy soon with a job.

EDIT: It's not difficult to convert from SDL to SFML and in some occasions, you might even reduce your lines of code. I can help you out with that if you want.
Last edited on
My only issue with SFML is that you can't dynamically change the window title. I wanted to display the framerate (I set vsync on so it's likely to stay at 60, but still) in the window title bar.

I might request an sf::Window::SetTitle() function or something.
closed account (y8h7M4Gy)
@computerquip thanks that would be great, message me here. http://elijah.mirecki.com/productions/contact.php :D ( edit: be sure to fill in the subject name and if your a bot or not or else it might turn out as spam )
@chrisname yeah. that shouldn't be TOO big of a problem haha
Last edited on
Nevermind... *sigh*
Last edited on
closed account (y8h7M4Gy)
did your first post not work?
closed account (y8h7M4Gy)
I found out how to change the title! lol.. its in the SFML tutorials

sf::Window App ( sf::VideoMode ( 800, 600, 32 ), "SFML Window, this is the title" );
So you want to recreate the window in every frame? Do you realise how slow that would be?
closed account (y8h7M4Gy)
you can probably set all the other operands to NULL like so...

sf::Window App ( NULL, "Handling Events!" );

i havent tried this but who knows
Then you'd have a NULL window. It doesn't work like that...
closed account (y8h7M4Gy)
Hmmm. oh well :P why dont you just have text ON the screen instead of on the title?
Well yeah, but it's much easier to set a window title than it is to write on the screen...
closed account (y8h7M4Gy)
Does it realy take that much time to configure truetype in an sfml window? as i recall it was pretty easy to do with SDL
Well, no; but it'd be easier to do something like
1
2
3
sf::Window window(sf::VideoMode::GetMode(0), "FKSDNSDKFG");

window.SetTitle("YAY");
closed account (y8h7M4Gy)
true... you might as well use freetype though right? if there realy is no way to change it... that is one thing i liked about SDL blah
oh well i like sfml so far.. i like the tutorials A LOT more because the SDL ones spoon fed you too much, these one you accualy have to think eh?
Uh... Am I missing something? sf::Window::SetTitle() seems to do exactly what you want to do.
Worst case scenario, you just write platform-specific code to set the caption. That's what I did when I needed to set it and wasn't sure whether the const char * SDL took was ANSI or UTF-8. I see SFML isn't any less retarded when it comes to string handling. Are there at least wide character versions?

As for the spoon-feeding, well, it is a tutorial. The author is already assuming (probably correctly) that the reader was too stupid to understand the extensive documentation.
@helios,
sf::Window::SetTitle() doesn't exist, does it? I made it up.

Are there at least wide character versions?

I don't know but I wouldn't be surprised. It has a lot of things.
closed account (y8h7M4Gy)
true xD
I made it up.
Oh. Never mind, then.

I don't know but I wouldn't be surprised.
Nope. Just checked. As retarded.
Pages: 123