[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] AES related question: How to keep track if my application



m0n0 wrote:

> > Why do you want to call it 100/s? For an average user 10/s or less seems
> > enough to me.
>
> 1. Because rendering calculations must take place, network packets must be
> cared of, etc. - If NetSurf is currently rendering a page and then calls
> my gui_poll function, it's bad if I break for about 100ms ... this just
> delays page rendering.

That's why you should *not* use a timeout of 1/100s but 1/10 or more.

>
> 2. Obviously this is not the case when rendering is finished. In that case
> I would like to use an envt_multi without timeout, but reporting every
> action I'm interested in...
> evnt_mult doesn't provide the key up / down. So I have to poll - if I just
> poll 10 times a second the user can hit the keyboard very
> fast and it looks like an key hold to me (and I miss an key up event)!

Well, if you show me how to press the same key 10 times per second, I'll
implement cubic and spherical rotating windows in XaAES. With textured background ;)

> Probably it is not realisitic that the user hits the keyboard more than 10
> times a second, and I shouldn't care about that.

Yep.

One problem that may occur is when you use too long for operations, or
wait for internet-input, and don't come to call evnt_multi and the user cannot do
anything. So you'll have to place timer-checks inside the code or you
need some sort of threads.

Maybe the XaAES-taskmanaager could be used for such cases to send a signal.

-Helmut