![]() |
|
set_keyboard_rate |
Serial H
Member #6,937
February 2006
|
Hi, |
Matt Smith
Member #783
November 2000
|
As far as I can recall (I've not been paying attention recently) this function only works in DOS because it calls the BIOS function. In other O/S the repeat rate is set by the O/S for all programs and allegro (deliberately?) refrains from changing system-wide parameters, as this would affect other users and programs. |
Birdeeoh
Member #6,862
February 2006
![]() |
This function works just great under Windows and Linux. Reread the docs on it - the order of the parameters is The repeat rate is "number of milliseconds between each key repeat" Here's some examples - //delay of 500ms, repeats 1000 times per second set_keyboard_rate( 500, 1 ); //delay of 100ms, repeats 10 times per second set_keyboard_rate( 100, 100 ); //delay of 1ms, repeats twice per second set_keyboard_rate( 1, 500 ); Good luck! [url http://developer.berlios.de/projects/openlayer/]OpenLayer[/url is an OpenGL accelerated 2D library for fast and easy graphics development under Allegro |
|