[SDL] hi another newbie here

Vardar Sahin sakirsoft at gmail.com
Thu Apr 12 14:08:13 PDT 2007


HI i don't know about windows positioning in SDL but you can tell SDL the
windows size


and to get mouse movenent infos you have too poll the SDL event list in your
main loop

 SDL_Event event;

 while( SDL_PollEvent(&event) )
 {
      switch( event.type )
       {
          SDL_MOUSEMOTION:
        //Mouse motion code

      break;

          SDL_MOUSEBUTTONDOWN:
        //Mouse button down code

      break;

          SDL_MOUSEBUTTONUP:
        //Mouse button up code

      break;




       }

}

you should take a look to the SDL API documentation for SDL_Event





2007/4/12, Engin Çalar <engincalar at gmail.com>:
>
> hi Im new at SDL,
> i was using opengl within glut before the sdl
> my problem is that in glut i could set the window position but in sdl i
> couldnt find it?(because of my ignorance?)
> and can you tell sth about mouse events(especially mousemotion) [in glut
> there was active and passive mouse motion]
> thanks in advance
>
>
> --
> Just say the words , your wish is my command..
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20070412/663e588c/attachment.htm 


More information about the SDL mailing list