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 - mercurio7891

Pages: 1 [2]
16
Window / Questions about sf::Input
« on: January 02, 2011, 03:09:51 am »
Hi, I am wondering how does sf::Input work, does it works as how the tutorial said? which is have a boolean variable to store the key state/mouse button state? And this boolean variable will be flag accordingly to the Event?

I roughly understand the need for sf::Input for realtime inputs. However I don't really understand why the need for sf::Input::GetMouseX/Y. Wouldn't the mouse position from the event suffice for realtime input?

Since I assume that whether a person get the mouse position from the Event or from the sf::Input, wouldn't it be the same until the next mouse move sf::event is fired?

regards

17
Window / mulitple sf::window and OpenGL
« on: December 31, 2010, 12:26:00 pm »
hi if i have multiple sf::Window, can they be on different threads? and if I am to call glBegin() glEnd() from a different thread will it work?

e,g
thread1 : sf::Window A
thread2 : sf::Window B
thread3 : sf::Window C
thread4 : glBegin()/glEnd() other opengl commands

is this allowed?? or mus all sf::Window(s) reside on the same thread along with all opengl commands?

18
Window / Can GetEvent or sf::Input be called from another thread?
« on: December 29, 2010, 10:34:10 am »
Hi I was wondering if sf::Window::GetEvent or sf::Input be used from another thread from that of which the window is created?

for example
thread 1: Create the Window and do all rendering (aka Graphics Thread)
thread 2: Physics Thread
thread 3: Main Loop where I call window::GetEvent or use the sf::Input here?

is this possible??

regards

19
Window / SFML error checking and exceptions
« on: December 27, 2010, 12:11:50 pm »
Hi, do SFML throw exceptions in any of the classes? If not how should I check for failures? for example when creating the sf::Window class, how would I know if the constructor failed? or sf::Window::Create failed?

20
Window / Is there anyway to specify the bit size for each channel?
« on: December 27, 2010, 08:10:00 am »
Hi I was wondering is there anyway to specify the channel size for each RGBA component when creating the window/opengl context?

regards

21
General / Static linking giving warning and mem leak in debug
« on: December 20, 2010, 11:36:52 pm »
Hi, I created a project in VS2010 and in debug mode, I link to
sfml-system-s-d.lib
sfml-window-s-d.lib

Code: [Select]

int main(int argc, char* args[])
{
    DETECT_MEMORY_LEAK;

    try
    {
        sf::Window App;
    }
    catch (std::exception& err)
    {
        std::cout << err.what() << "\n";
    }

    std::cin.get();

    return 0;
}


however when i compile it gives a lot of warning:
Code: [Select]

1>sfml-system-s-d.lib(Platform.obj) : warning LNK4099: PDB 'vc100.pdb' was not found with 'sfml-system-s-d.lib(Platform.obj)' or at 'C:\ Framework\Debug\vc100.pdb'; linking object as if no debug info
1>sfml-system-s-d.lib(Clock.obj) : warning LNK4099: PDB 'vc100.pdb' was not found with 'sfml-system-s-d.lib(Clock.obj)' or at 'C:\Framework\Debug\vc100.pdb'; linking object as if no debug info


but it still run fines. I guess because it can't find the symbol to load for debugging?

However when I exit the program. The CRT is detecting a number of memory leaks. I am using the _CrtDumpMemoryLeaks() along with _CrtSetDbgFlag(), to check for memory leaks.

regards

Pages: 1 [2]
anything