I've been playing with gapidraw on my toshiba e740. When I run the collisionmask sample program and move the sprite around with the keypad I've noticed quite a bit of latency from when I stop pressing a direction and when the sprite actually stops moving. From the on-screen values I'd say it moves 3-4 pixels after I release.
The program is pretty simple so I'm at a loss to explain it from software- but 132 msec lateny doesn't seem likely to be hardware either.
Is anyone familiar with this?
Not sure but it may be the wrong latency you are thinking about.
Its possible in line with your draw cycle (since they are connected since you are moving the sprite with the key) you are creating a small backlog of press messages, that you are unable to catch up with (for instance the press events are sent faster than your draw cycle) so once you are done you see the last messages getting processed.
I've seen the above for things like mouse movement and dragging, but not yet with keys, could be the problem though.
I've noticed the same thing with the little programs I've written. So far I've tried to compensate with things like only processing movement every other frame, stuff like that. It's not the greatest solution and definitely isn't for every game, but it helps sometimes. I'd be much happier if there was a better solution! :)
BTW, if I understand the suggestion in the previous post correctly, that's not the issue -- at least not in my programs. I'm targeting and hitting 30 fps, so that shouldn't allow messages to queue up, right? I'd expect that to happen if I were taking too long for each frame.
I'll se what I can add to gapiapplication in the 1.1 beta to fix this...
sbl- I'm not sure how you can code around it. I posted in a new thread that I verified the problem, it occurs on 3 different models of toshiba's that I tried- and it occurs even in simple MFC programs: there is a ~100 msec latency from the time a key is released to the time the key up message comes in windows. But if you can, kudos to you.
-Paul
What I was thinking of is to force a flush of all messages from the message queue before proceeding to the next frame (if the issue is simply that the 740 posts too many messages that the application can handle). This would on the other hand lower the FPS of the game...I have a bunch of e740's lying around so I could test some and see if it makes a difference.
sbl- as far as I can tell it is not a problem with too many messages in the queue. Rather, the keypad driver or perhaps the hardware itself (maybe some debouncing logic) delays giving the message to the OS. My test program was a simple MFC app that didn't even use gapidraw- simply recorded time on key_down message and key_up message. No matter how quickly I attempted to hit the key there was never less than 100 msec delay. (vs. as low as 8msec on a dell axim). At any rate, perhaps you'll discover something interesting. Please followup if you do.
regards,
Paul
This device seems to be a true piece of crap. Slow video, delayed key-presses... it's a shame that until now noone's noticed.