|
From: Mike A. <mi...@mi...> - 2005-07-18 18:52:20
|
Richard Rauch wrote: >On Sun, Jul 17, 2005 at 01:56:41PM -0700, Mike Austin wrote: > > >>Richard Rauch wrote: >> >> > [...] > > >>>If MsgWait*() works, I'd suggest staying with that. >>> >>> >>> >>To my knowledge there was no sleep or wait call in fgSleepForEvents(), >>so I first added a MsgWait(). The timeout needed to be the smallest >> >> > >Looks like it's there, to me. > >Possibly it is incorrectly done and does not sleep properly, but >the line of code is there, I think. > > Io is currently using 2.2.0 and it is not there, so it was probably added recently. > > >>possible, so the call was not any more efficient than plain Sleep(), >> >> > >Why wouldn't it be? > >With waiting for multiple events, you can wait more or less indefinitely >if there are no timer-based events and no idle callback. (Regrettably, >legacy joystick support is timer-based polling, which messes up things.) > > Yes, it can be more efficient. But like you say, timers and the idle callback require the least amount of blocking. If there are no timers or an idle callback, I guess the timeout could be set to INFINITE. I don't know if it's really worth doing, >>especially since vertical sync is going to make your app wait anyway. >>Well, I guess it depends on how your app is written. >> >> > >Yep...it does depend on the application. (^& > > > > |