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

Author Topic: SFGUI (0.4.0 released)  (Read 347833 times)

0 Members and 1 Guest are viewing this topic.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 10801
    • View Profile
    • development blog
    • Email
Re: SFGUI (0.2.3 released)
« Reply #540 on: April 07, 2014, 08:28:51 am »
From the official website:

Quote
Why isn't there support for older Visual Studio/GCC/whatever versions?
SFGUI makes use of modern C++11 features, such as range-based for loops, std::function, std::bind, move semantics and many more. If you're using a compiler that does not yet support those features, you won't be able to use SFGUI. Please upgrade your toolchain.

I'm not 100% certain, but I think VS 2013 should work.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Theshooter7

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #541 on: April 08, 2014, 05:04:28 am »
I see. VS2012 did support the things listed (std::function, std::bind, etc.) but I know it's implementation was not 'complete'. Thus, it seems an upgrade is needed then. :(

lolz123

  • Sr. Member
  • ****
  • Posts: 260
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #542 on: April 08, 2014, 05:48:55 am »
I'm using VS2013, works perfectly for me! Just integrated it into D3D  :) Great lib!
Have you heard about the new Cray super computer?  It’s so fast, it executes an infinite loop in 6 seconds.

Lolilolight

  • Hero Member
  • *****
  • Posts: 1232
    • View Profile
Why using RAII everywhere ?
« Reply #543 on: May 26, 2014, 12:54:21 pm »
Hi!

There is a question that I would like to ask.

In sf::GUI. (and not only in sf::GUI but also in some other project like thor)

You are using RAII everywhere (even for function pointer and member variables)

If I want to create a gui I'm forcing to use an std::shared_pointer.

I don't thing automatic memory management is a part of the new standart of the c++11.
Memory management in a c++ class depends on the class semantic and have to be managed by the destructor and by the copy constructor and the operator= overload.

smart pointers have to be used only for non member variables and especially in an exception context exactely like the std::lock_guard class (to unlock the mutex event if an exception is generated)

So I don't understand the interest of using RAII everywhere. :/



Grimshaw

  • Hero Member
  • *****
  • Posts: 631
  • Nephilim SDK
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #544 on: May 26, 2014, 02:16:14 pm »
Please teach us how it should be done :D

Lolilolight

  • Hero Member
  • *****
  • Posts: 1232
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #545 on: May 26, 2014, 02:26:07 pm »
Me ?
I just learned to use smart pointers (=RAII) which try/catch clauses only and in the other cases to use the copy, move constructor, the operator= and the destuctor if it's necessary. (It depends on the semantic of the class, if the class have interna pointers and if the values of the internal pointers have to be copied or not and if the class have to create or delete the pointers)

It avoids to have too much abstraction. (I really hate that. :/)

The only exemple when I use RAII.

Resource* r = new Resource();
std::unique_ptr<Resource>(r);
try {
} catch {
}
 

And the std:::shared_pointer if you pass the pointer to another function in the try catch blocks.
« Last Edit: May 26, 2014, 02:30:16 pm by Lolilolight »

Grimshaw

  • Hero Member
  • *****
  • Posts: 631
  • Nephilim SDK
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #546 on: May 26, 2014, 02:37:05 pm »
We are blessed to receive your teachings :)

Jesper Juhl

  • Hero Member
  • *****
  • Posts: 1405
    • View Profile
    • Email
Re: SFGUI (0.2.3 released)
« Reply #547 on: May 26, 2014, 03:52:44 pm »
The only exemple when I use RAII.

Resource* r = new Resource();
std::unique_ptr<Resource>(r);
 
Why the intermediate variable "r"?

For C++11, just use:
  auto ptr = std::unique_ptr<Resource>(new Resource);

In C++14 you have an even better solution in the form of std::make_unique

Lolilolight

  • Hero Member
  • *****
  • Posts: 1232
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #548 on: May 26, 2014, 04:41:08 pm »
Ok I can also do that...

Can't wait until the c++14.  :D

Grimshaw

  • Hero Member
  • *****
  • Posts: 631
  • Nephilim SDK
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #549 on: May 26, 2014, 07:52:52 pm »
Yeah, I hope you are still around when it comes out so you can teach us some more new tricks :D It would be awesome.

StormWingDelta

  • Sr. Member
  • ****
  • Posts: 365
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #550 on: February 18, 2015, 01:04:47 am »
This project still being updated?  Was hunting around for this and other GUIs to use with SFML and thought it might be useful for what I'm up to. :)
I have many ideas but need the help of others to find way to make use of them.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 10801
    • View Profile
    • development blog
    • Email
Re: SFGUI (0.2.3 released)
« Reply #551 on: February 18, 2015, 01:07:20 am »
Last commit Feb 4, 2015. Is it still being updated? ::)

Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

StormWingDelta

  • Sr. Member
  • ****
  • Posts: 365
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #552 on: February 18, 2015, 01:09:28 am »
lol guess it would have helped if I had looked in the comments section.   :-[
I have many ideas but need the help of others to find way to make use of them.

Sub

  • Full Member
  • ***
  • Posts: 157
    • View Profile
Re: SFGUI (0.2.3 released)
« Reply #553 on: February 18, 2015, 02:53:07 am »
A lot can happen in two weeks  ;)

Neomex

  • Newbie
  • *
  • Posts: 28
    • View Profile
    • Email
Re: SFGUI (0.2.3 released)
« Reply #554 on: April 23, 2015, 06:49:09 pm »
Could someone provide binaries for visual studio 2013? Pretty please?

I have spent last two hours getting cmake to work and now it doesn't compile :(

Error   1   error LNK1107: invalid or corrupt file: cannot read at 0x2E8   C:\ProgrammingLibraries\SFML-2.2\bin\sfml-graphics-d-2.dll   1   1   sfgui

 

anything