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

Author Topic: SFML 2.0 RC  (Read 116562 times)

0 Members and 1 Guest are viewing this topic.

reta

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: SFML 2.0 RC
« Reply #90 on: May 19, 2012, 01:39:40 am »
Hello,

I have a problem with the git version of CSFML, when I try to compile I get the error:

undefined reference to `sfWindow_setSize'

If I remove this function call, there isn't any error anymore, and the compilation succeed.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: SFML 2.0 RC
« Reply #91 on: May 19, 2012, 07:55:13 am »
The function exists, make sure that you use a rencent revision of CSFML, that you properly compiled it, and that you're not mixing with an older version.
Laurent Gomila - SFML developer

reta

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: SFML 2.0 RC
« Reply #92 on: May 20, 2012, 03:07:48 am »
yes it is a recent version of the GIT, I downloaded/compiled it again just before posting.

and indeed it is a weird error, because the function is there, without any case error.

1.6 is also arround but I mouved it outside of /usr/lib, I put it in /usr/lib/sfml-1.6/ so if I don't provide this path it should not be found
(I also moved the 1.6 includes)

I have this error only with this particular function. And I have no idea why because it's there in the sources.
If I remove this function from my sources, there is no error.

I have not tryed yet to test from a more simple hello world example. I'll do tomorrow.
« Last Edit: May 20, 2012, 03:10:37 am by reta »

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: SFML 2.0 RC
« Reply #93 on: May 20, 2012, 09:11:48 am »
I remember another user having a similar issue with sfImage_createMaskFromColor. The function is well defined and exported, but missing from the compiled libraries.
Laurent Gomila - SFML developer

reta

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: SFML 2.0 RC
« Reply #94 on: May 21, 2012, 06:01:08 pm »
Hi,
It seems that there is a problem with sfMouse_getPosition() and sfMouse_setPosition().
It seems that it provides interaction with sfWindow but not with sfRenderWindow.

cheers

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: SFML 2.0 RC
« Reply #95 on: May 21, 2012, 10:23:58 pm »
Indeed. That's a problem.
Laurent Gomila - SFML developer

MorleyDev

  • Full Member
  • ***
  • Posts: 219
  • "It is not enough for code to work."
    • View Profile
    • http://www.morleydev.co.uk/
Re: SFML 2.0 RC
« Reply #96 on: May 21, 2012, 11:34:35 pm »
Hmm, interesting. Mostly playing around with some odd threading stuff here. I made a system where you have n threads (where n is the hardware concurrency), and the first available thread grabs any tasks that are pushed onto a concurrent fifo task queue and executes them.

Now, originally I had it written so one of those tasks was the final render pass, which does the drawing to an sfml window and the window.display(). The window inputs always happened on the main thread (which was separated from this task system by making it just wait for tasks and then run those tasks, letting other threads "jump into" the main thread for a bit, kinda inefficient but as a stopgap solution it worked).

This worked fine when I was running it with my integrated graphics card (NVIDIA Optimus technology defaulted to this for the unrecognised executable), regardless of how many threads I was using. However,when n was >= 5 (meaning 6 or more threads were in use, one main thread and 5 task threads) it'd render a few frames and then crash.

Modifying the code so both final render and input polling occurred on the main seemed to fix this problem so I'm putting it down under "nvidia opengl multithreading weirdness" and "you dolt, graphics cards are not meant to run on potentially different threads in the same program every render" and moving on.
« Last Edit: May 22, 2012, 08:30:38 am by MorleyDev »
UnitTest11 - A unit testing library in C++ written to take advantage of C++11.

All code is guilty until proven innocent, unworthy until tested, and pointless without singular and well-defined purpose.

reta

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: SFML 2.0 RC
« Reply #97 on: May 22, 2012, 09:12:24 pm »
Indeed. That's a problem.

Do you plan to resolve this for the 2.0 release ?

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: SFML 2.0 RC
« Reply #98 on: May 22, 2012, 11:31:42 pm »
Quote
Do you plan to resolve this for the 2.0 release ?
I'll try.
Laurent Gomila - SFML developer

talanak

  • Newbie
  • *
  • Posts: 1
    • View Profile
Re: SFML 2.0 RC
« Reply #99 on: May 24, 2012, 06:05:11 am »
Hi Laurent!

I've not been able to compile with <SFML/Network/Http.h> except if I make the change below in the header file.

Also Ftp.hpp and Http.hpp are in Network.hpp, but Ftp.h and Http.h are not in Network.h, so the patch below correct this too.


diff -Naur LaurentGomila-CSFML-bfebe0a/include/SFML/Network/Http.h CSFML_git_2012-05-24/include/SFML/Network/Http.h
--- LaurentGomila-CSFML-bfebe0a/include/SFML/Network/Http.h     2012-05-22 17:56:01.000000000 +0200
+++ CSFML_git_2012-05-24/include/SFML/Network/Http.h    2012-05-24 05:55:57.000000000 +0200
@@ -37,19 +37,19 @@
 /// \brief Enumerate the available HTTP methods for a request
 ///
 ////////////////////////////////////////////////////////////
-enum sfHttpMethod
+typedef enum
 {
     sfHttpGet,  ///< Request in get mode, standard method to retrieve a page
     sfHttpPost, ///< Request in post mode, usually to send data to a page
     sfHttpHead  ///< Request a page's header only
-};
+} sfHttpMethod;
 
 
 ////////////////////////////////////////////////////////////
 /// \brief Enumerate all the valid status codes for a response
 ///
 ////////////////////////////////////////////////////////////
-enum sfHttpStatus
+typedef enum
 {
     // 2xx: success
     sfHttpOk        = 200, ///< Most common code returned when operation was successful
@@ -78,7 +78,7 @@
     // 10xx: SFML custom codes
     sfHttpInvalidResponse  = 1000, ///< Response is not a valid HTTP one
     sfHttpConnectionFailed = 1001  ///< Connection with server failed
-};
+} sfHttpStatus;
 
 
 ////////////////////////////////////////////////////////////
diff -Naur LaurentGomila-CSFML-bfebe0a/include/SFML/Network.h CSFML_git_2012-05-24/include/SFML/Network.h
--- LaurentGomila-CSFML-bfebe0a/include/SFML/Network.h  2012-05-22 17:56:01.000000000 +0200
+++ CSFML_git_2012-05-24/include/SFML/Network.h 2012-05-24 05:55:20.000000000 +0200
@@ -30,6 +30,8 @@
 ////////////////////////////////////////////////////////////
 
 #include <SFML/System.h>
+#include <SFML/Network/Ftp.h>
+#include <SFML/Network/Http.h>
 #include <SFML/Network/IpAddress.h>
 #include <SFML/Network/Packet.h>
 #include <SFML/Network/SocketSelector.h>
 

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: SFML 2.0 RC
« Reply #100 on: May 24, 2012, 07:53:40 am »
Thanks :)
Laurent Gomila - SFML developer

Bread

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: SFML 2.0 RC
« Reply #101 on: May 28, 2012, 10:19:34 am »
Hey Laurent,

Is there a problem with the server that is hosting the C++ RC 2.0 files?

I'm getting literally <500 bytes/second.

Thanks,
Bread

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Re: SFML 2.0 RC
« Reply #102 on: May 28, 2012, 10:37:04 am »
There's no known problem. I just tried to download something and got more than 1 MB/s.
Laurent Gomila - SFML developer

Bread

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: SFML 2.0 RC
« Reply #103 on: May 28, 2012, 10:45:12 am »
Ok, it must be something on my end.. other networks seem to be downloading it fine.

Thanks for the quick reply! I'm looking forward to making these forums my home haha.

kaB00M

  • Full Member
  • ***
  • Posts: 101
    • View Profile
    • Caffeware
    • Email
Re: SFML 2.0 RC
« Reply #104 on: May 29, 2012, 01:19:22 am »
No flip function for the Sprite class?  :'(