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

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - seb.dd

Pages: [1]
1
Window / OSX: GetFrameTime() causes SIGABRT signal
« on: October 30, 2009, 07:52:14 pm »
GetFrameTime() causes a SIGABRT signal after Close() was called on the render window.
the signal is recieved at the return of test() and kind of crashes the application.

Code: [Select]

int test()
{
// Create the main window
sf::RenderWindow App(sf::VideoMode(800, 600, 32), "SIGABRT");
App.PreserveOpenGLStates(true);

// Start main loop
while (App.IsOpened())
{
// Process events
sf::Event Event;
while (App.GetEvent(Event))
{
            if (Event.Type == sf::Event::Closed) App.Close();
}

App.Clear();

// fps
char buffer[16];
int fps = 100;
fps = int(1.f / App.GetFrameTime()); // this causes the signal
sprintf(buffer, "fps = %d", fps);
App.Draw(sf::String(buffer));

App.Display();
}

return EXIT_SUCCESS;
}

int main()
{
return test();
}

2
General / can't compile first tutorial on intel macbook pro (xcode)
« on: October 26, 2009, 05:28:58 pm »
this is the code:
Code: [Select]

////////////////////////////////////////////////////////////
// Headers
////////////////////////////////////////////////////////////
#include <SFML/Window.hpp>


////////////////////////////////////////////////////////////
/// Entry point of application
///
/// \return Application exit code
///
////////////////////////////////////////////////////////////
int main()
{
    // Create the main window
    sf::Window App(sf::VideoMode(800, 600, 32), "SFML Window");

    // Start main loop
    bool Running = true;
    while (Running)
    {
        App.Display();
    }

    return EXIT_SUCCESS;
}


i get 220 preprocessor and compiler errors. first in the list is:
Quote
Config.hpp:122:19: error: climits: No such file or directory


in case the crt library is not linked correctly. how do i do it manually?
may be some of the million project build settings must be adjusted,
but the starting tutorial alone doesn't do it...

3
Graphics / OpenGL / VC++ / GLU / Linker
« on: October 21, 2009, 03:55:40 pm »
building a project from my XCode/MacOS source code on VC++/Vista got me a lot of trouble... especialy the use of opengl.

i still get this linker error:
Quote
unresolved external symbol _gluPerspective@32 referenced in function ...


includes:
Quote
#include <SFML/Graphics.hpp>
#include <GL/glu.h>


seems like GLU isn't linked correctly.

another problem is that: classes that must be independent of sfml but rely on gl.h produce strange compiler errors. it complains about missing ';' before 'WINGDIAPI' in gl.h.

what should i look for?

4
Window / 2 mouse event questions
« on: October 15, 2009, 04:45:57 pm »
hello everyone! after getting a lot of help from reading the forum i finally registered :)

first i must admit how i love the framework!

i've been looking for such a thing for a long time, did a lot of comparing,
messed around with sdl and even started writing my own cross platform
library before discovering this rising star. it's exactly what i never hoped to find.


what i like to know:

1)  the mouse move event holds the absolute mouse position wich i'm not
interested in when processing a move event. i could read absolute values
from sf::Input as well. to get delta values i have to save the old position
each frame and manually compute the difference. so in the end the move
event makes no sense to me at all. is there an easier way to get relative
movement values when processing a mouse move event or will this be
fixed in future releases?

2) when scrolling in some application like firefox my mouse wheel works
fine: each "wheel click" moves the page a little. when "scrolling" on my
sfml window it takes around 10 "wheel clicks" in the same direction to
finally fire a mouse wheel event which might be exhausting for the user ;)
(setup: osx / sfml 1.5 / windowed mode) any ideas?

Pages: [1]