Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: SFML 2.0 tutorials  (Read 2375 times)

0 Members and 1 Guest are viewing this topic.

Karleon

  • Newbie
  • *
  • Posts: 18
    • View Profile
SFML 2.0 tutorials
« on: November 09, 2012, 03:05:23 pm »
Hello,

I had experience with Allegro and ClanLib, but decided to move to SFML or SDL.

I finally decided to use SFML, and I have set up the development enviroment.
I decided to try SFML 2.0, but now I see that the tutorial section for 2.0 seems pretty lackluster... Does the tutorials for 1.6 work with version 2.0?

Does the 2.0 tutorials only explain new stuff from previous versions?

In case I'm not really experienced with SFML, is it better to use version 1.6 and it's tutorials?


Thanks in advance!

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: SFML 2.0 tutorials
« Reply #1 on: November 09, 2012, 03:24:40 pm »
Does the tutorials for 1.6 work with version 2.0?
Depends on your definition of "work". :P
You can't copy the code since there's a major API change between 1.6 and 2.0, but the principles are mostly the same, so the prinziples "work". ;)

Does the 2.0 tutorials only explain new stuff from previous versions?
No, they just haven't been finished yet.

In case I'm not really experienced with SFML, is it better to use version 1.6 and it's tutorials?
Well I'd advise you to start with SFML 2, because it's less than 1.6, has more features and you won't have to relearn everything once SFML 2 is stable. ;)

Also keep in mind that there's a very detailed documentation which will makes things much easier.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

didii

  • Full Member
  • ***
  • Posts: 122
    • View Profile
Re: SFML 2.0 tutorials
« Reply #2 on: November 10, 2012, 02:47:08 pm »
Indeed, the tutorials aren't finished yet but 2.0 works almost the same as 1.6 if you're just starting. I started learning in 1.6 and when I finished the tutorials of it I almost immediately went to 2.0 (since the recommendations in this forum). If you just started it's really not an issue. The only thing you'll have to adapt is that most functions now don't use capitals anymore, GetEvent() changed to pollEvent() and some other logical changes (like sf::Key to sf::Keyboard and such). That will be the major changes for going from 1.6 to 2.0 if you don't know much of SFML yet (which is the case for me ;D)
So I advice to read the available tutorials of 2.0, and for the ones that are not finished yet, those of 1.6. But do try to program them in 2.0 instead. Best of luck! Any questions: just ask here :)

EDIT: oh and mind the difference between sf::Texture and sf::Image. Search the forum a bit to know the difference between them. sf::Sprites now only take sf::Textures and not a sf::Image anymore.
« Last Edit: November 10, 2012, 02:52:22 pm by didii »

masskiller

  • Sr. Member
  • ****
  • Posts: 284
  • Pointers to Functions rock!
    • MSN Messenger - kyogre_jb@hotmail.com
    • View Profile
    • Email
Re: SFML 2.0 tutorials
« Reply #3 on: November 10, 2012, 05:16:00 pm »
There's also stuff that is not included in the 1.6 tutorials at all, which require a bit more of a workout, like Vertexes and VertexArrays. I think there was going to be a new tutorial for handling VertexArrays (since it did not exist in 1.6), but I'm not sure. At any rate there's also the wiki which has lots of code about a bunch of stuff you can do.
« Last Edit: November 10, 2012, 05:22:33 pm by masskiller »
Programmer, Artist, Composer and Storyline/Script Writer of "Origin of Magic". If all goes well this could turn into a commercial project!

Finally back into the programming world!

 

anything