On Mon, Jul 23, 2012 at 8:31 PM, Tristam MacDonald <[email protected]> wrote:
> On Mon, Jul 23, 2012 at 6:46 AM, anatoly techtonik <[email protected]>
> wrote:
>>
>> Hi,
>>
>> What is the correct way to initiate window redraw?
>
>
> What's wrong with scheduling an update function? IIRC, that should trigger a
> redraw whenever it occurs.
>
> def update(dt):
>     pass
>
> pyglet.clock.schedule_interval(update, 1/60.0)

Thanks. Surprisingly, an empty update() call kicks event loop as
expected. I want to measure maximum FPS possible on 100% CPU load, so
a 1/10000 value looks good for my case. But for the clarity I'd still
prefer to kick event loop explicitly. Unfortunately, Google Code
Hosting is down at the moment and don't allow me to browse the sources
to see how is it implemented.
--
anatoly t.

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

Reply via email to