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

Author Topic: Thor 2.0 released!  (Read 341771 times)

0 Members and 2 Guests are viewing this topic.

DJuego

  • Jr. Member
  • **
  • Posts: 50
    • View Profile
Re: Thor 2.0
« Reply #15 on: March 29, 2012, 07:34:20 pm »
I'm having a problem trying to compile Thor with CMake.  Specifically I'm getting the same SFML_DIR-NOTFOUND error (whether I change SFMLDIR or SFML_DIR it always comes out with the same error). I have SFML installed from the git tutorial.
I think you have to install SFML, not just build it (the CMake install command copies the FindSFML file). You have to type make install (using g++) or compile the INSTALL project (Visual Studio).

Correct.  I am not accustomed "to install" libraries. I don't like. Perhaps it will be enough relocating the folder 'cmake/Modules/findSMFL' to the 'installation directory'.

On the other hand I can not meta-build the examples with CMake-2.8.7
What do you mean with meta-build? The examples/CMakeLists.txt file cannot be used autonomously, it is invoked by the top-level CMakeLists.txt.


Forget it! I am a *noob* with CMake.  :'(  My problem...

Code: [Select]
1>------ Build started: Project: ZERO_CHECK, Configuration: Release Win32 ------
2>------ Build started: Project: Particles, Configuration: Release Win32 ------
2>  Particles.cpp
2>W:\Librerias-VS2010\SFML\Bromeon-Thor-9b4b3d9\examples\Particles.cpp(111): error C2664: 'sf::Vector2f sf::RenderTarget::convertCoords(const sf::Vector2i &,const sf::View &) const' : cannot convert parameter 1 from 'unsigned int' to 'const sf::Vector2i &'
2>          Reason: cannot convert from 'unsigned int' to 'const sf::Vector2i'
2>          No constructor could take the source type, or constructor overload resolution was ambiguous
========== Build: 1 succeeded, 1 failed, 1 up-to-date, 0 skipped ==========

Sorry! You need update the git snapshot Thor to the new *SFML* commits.  ;D

Thank you for your dedicated attention, Nexus!

DJuego
« Last Edit: March 29, 2012, 08:15:48 pm by DJuego »

Astrof

  • Full Member
  • ***
  • Posts: 135
    • View Profile
Re: Thor 2.0
« Reply #16 on: March 29, 2012, 07:40:14 pm »
I'm having a problem trying to compile Thor with CMake.  Specifically I'm getting the same SFML_DIR-NOTFOUND error (whether I change SFMLDIR or SFML_DIR it always comes out with the same error). I have SFML installed from the git tutorial.
I think you have to install SFML, not just build it (the CMake install command copies the FindSFML file). You have to type make install (using g++) or compile the INSTALL project (Visual Studio).


I did use make Install to install it (I even did a clean then install and it didn't work; for some reason the .cmake file wasn't being copied to the modules folder (even with all admin privileges and everything set)).  Manually copying the file over however did fix it.  If it helps I was using mingw and Codeblocks and not Visual Studio as I don't have Visual Studio installed on this computer. 


Also are the tutorials outdated on your website? I tried some of the tutorials (specifically the particles one) and it seems certain classes have changed.  Overall everything is awesome I just have to play around with it a bit more.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: Thor 2.0
« Reply #17 on: March 29, 2012, 08:39:21 pm »
FindSFML.cmake is no longer automatically copied to the CMake install directory, you need to do it manually, or add the path where it is to the CMAKE_MODULE_PATH CMake variable so that it can find it.
Laurent Gomila - SFML developer

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6286
  • Thor Developer
    • View Profile
    • Bromeon
Re: Thor 2.0
« Reply #18 on: March 30, 2012, 06:10:06 pm »
I am not accustomed "to install" libraries. I don't like.
Why not? I think it's the best option to setup everything automatically and correctly.

Also are the tutorials outdated on your website?
Yes, the tutorials for the new version have not been written yet, since several things may still change.

Overall everything is awesome I just have to play around with it a bit more.
Thanks! If you have some ideas, just tell me! :)

FindSFML.cmake is no longer automatically copied to the CMake install directory
Why have you changed that? This was an easy way to use SFML in other projects. I fear this problem is going to come up often in the future, since people are usually not very familiar with CMake. And I'm glad about every single step the user needn't do on his site to compile a project...
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: Thor 2.0
« Reply #19 on: March 30, 2012, 08:47:41 pm »
Quote
Why have you changed that?
It could require admin rights.
I think it's generally a good idea to avoid copying stuff outside the SFML install dir, because the user doesn't have much control on that.

Quote
I fear this problem is going to come up often in the future, since people are usually not very familiar with CMake
People playing with CMake are usually not beginners, there are public releases for them ;)
Laurent Gomila - SFML developer

Astrof

  • Full Member
  • ***
  • Posts: 135
    • View Profile
Re: Thor 2.0
« Reply #20 on: March 31, 2012, 06:10:12 am »
Thanks! If you have some ideas, just tell me! :)

For sure! Though I'm a bit rusty on my programming with med school and all.  Once SFML (and Thor) 2.0 get "finalized" I'd love more/new tutorials!

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6286
  • Thor Developer
    • View Profile
    • Bromeon
Re: Thor 2.0
« Reply #21 on: March 31, 2012, 10:11:06 am »
People playing with CMake are usually not beginners, there are public releases for them ;)
There are still many people following the development version, and for that no in-depth CMake knowledge has been required up to now. The current need to manually copy files is not standing to reason, especially if it's undocumented. I think this might also be difficult to document, since the CMake module directory is different depending on how CMake has been installed.

Was it really a problem, did many users have issues with admin rights? What about an optional checkbox in SFML's CMakeLists configuration, so that the user could choose whether FindSFML should be copied?

Once SFML (and Thor) 2.0 get "finalized" I'd love more/new tutorials!
I'll certainly update the old tutorials, do you have concrete parts of the library in mind for which I should write new ones? Animation might be such a candidate, others?
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: Thor 2.0
« Reply #22 on: March 31, 2012, 10:32:27 am »
Quote
Was it really a problem, did many users have issues with admin rights?
It happens, yes. A typical configuration is a Linux where you have rights only in your home folder; in this case users will try to install SFML to, let's say, /home/laurent/libs/sfml but it will fail because it will attempt to install something to /usr/share/CMake/modules.

Quote
What about an optional checkbox in SFML's CMakeLists configuration, so that the user could choose whether FindSFML should be copied?
I don't even know if it's the right solution; don't forget that there's another option which is to tell CMake where FindSFML.cmake is located.
Laurent Gomila - SFML developer

Astrof

  • Full Member
  • ***
  • Posts: 135
    • View Profile
Re: Thor 2.0
« Reply #23 on: March 31, 2012, 08:09:21 pm »
I'll certainly update the old tutorials, do you have concrete parts of the library in mind for which I should write new ones? Animation might be such a candidate, others?

Right now I'm mainly using the Particle Systems part of Thor, along with any Aurora things with it.  What confused me, at least initially, was going from different emitters to a UniversalEmitter. 

As for the cmake file and admin rights, what I (and maybe other Windows users) do is just run everything as administrator, especially when running install commands (as without it the install command doesn't work).  Horrible practice but it works. 

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: Thor 2.0
« Reply #24 on: March 31, 2012, 08:17:06 pm »
Quote
As for the cmake file and admin rights, what I (and maybe other Windows users) do is just run everything as administrator, especially when running install commands (as without it the install command doesn't work).
My point was that sometimes you can't have the admin rights.
Laurent Gomila - SFML developer

Astrof

  • Full Member
  • ***
  • Posts: 135
    • View Profile
Re: Thor 2.0
« Reply #25 on: April 01, 2012, 12:25:16 am »
My point was that sometimes you can't have the admin rights.

Ah true then I like the idea of pointing cmake to the FindSFML file. 

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6286
  • Thor Developer
    • View Profile
    • Bromeon
Re: Thor 2.0
« Reply #26 on: April 02, 2012, 05:44:06 pm »
What confused me, at least initially, was going from different emitters to a UniversalEmitter.
But do you like the new approach? And is the documentation detailed enough to understand how it works? I uploaded a first version of an updated tutorial not to leave users in the dark, however there are still some parts to improve.

By the way, I am probably going to enforce C++11 in Thor, as it makes a lot really simpler. Especially move semantics, lambda expressions and the smart pointers are extremely useful. And in the end, it's also better for the users because there are less wheel reinventions in my library ;)
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

Astrof

  • Full Member
  • ***
  • Posts: 135
    • View Profile
Re: Thor 2.0
« Reply #27 on: April 02, 2012, 08:46:41 pm »
I do like the new approach; I like how it's more customizable however it does require the user to do more work themselves (yes I'm lazy lol).  The documentation is also really well done so it just takes a bit of reading to learn.  Again something that threw me off was the PolarVector; I've never used a polar vector to draw before (except on a TI-83). 


If I have any specific questions on functionality/how to do something should I just message you directly (instead of posting everything on this thread)?

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 10801
    • View Profile
    • development blog
    • Email
Re: Thor 2.0
« Reply #28 on: April 02, 2012, 09:03:34 pm »
Laurent changed tha API again (no more getHeight getWidth on textures)...  ::)

So we can't compile Thor 2.0 anymore.
« Last Edit: April 02, 2012, 09:07:07 pm by eXpl0it3r »
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6286
  • Thor Developer
    • View Profile
    • Bromeon
Re: Thor 2.0
« Reply #29 on: April 03, 2012, 02:21:38 pm »
however it does require the user to do more work themselves (yes I'm lazy lol).
I thought it became easier ;)
What do you have to do in addition at the moment?

TAgain something that threw me off was the PolarVector; I've never used a polar vector to draw before
thor::PolarVector2 is just another representation of sf::Vector2, using polar coordinates. It's not mandatory, you can also use sf::Vector2 and the functions thor::rotate() and thor::rotatedVector() to turn them, PolarVectors just make some parts easier (and partially more efficient and precise)...

If I have any specific questions on functionality/how to do something should I just message you directly (instead of posting everything on this thread)?
Yes. If the questions are rather general (design, API, ...), you can post them here ;)

Laurent changed tha API again (no more getHeight getWidth on textures)...  ::)

So we can't compile Thor 2.0 anymore.
Thanks, I'll fix it as soon as possible.
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development: