How to listen to events without opening a window?

0

I'm doing a simple personal console project that will do keyboard hooking , but I do not want it to open the SFML OpenGL window. Is there any way to listen to SFML events without opening a window?

    
asked by anonymous 27.07.2014 / 01:59

1 answer

0

You just need to hear the event inside a thread. In generic code, for example:

void callback()
{
    while(true)
    {
        if(pressionado(tecla))
        {
            // o que for necessário
        }
    }
}

And then the function is inserted into a thread.

    
21.04.2015 / 20:58