On Oct 14, 11:19 pm, Tristam MacDonald <[email protected]> wrote: > On Wed, Oct 14, 2009 at 5:57 PM, Doeke <[email protected]> wrote: > > When you are providing keyboard/mouse events, that is pretty much the > behaviour I would expect. > > schedule_interval doesn't seem to make any guarantees about how often you > function will be called - and in general it can't.
I would have thought that it could 'catch up' by calling the function more often when it finds that it is behind. Maybe this isn't practical with however pyglet handles its scheduling. > As I see it, there are three ways to reasonably deal with this: > > a) live with it, and deal with the issues it creates > b) implement your own 'busy' run loop, and thrash the CPU > c) use a real-time OS, and add real-time support to pyglet The elegant nature of being able to schedule update functions in pyglet looked quite appealing to me originally, but the more I think about it the more pitfalls I see with the approach - especially if regular input is harming logic update frequency to such an extent that 50fps drops to 30fps. Is there an example of implementing the typical game loop with pyglet, and how it is (or isn't) compatible with the scheduler? -- Ben Sizer --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pyglet-users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en -~----------~----~----~----~------~----~------~--~---
