# Keyboard camera rotation. Initial jerk

**URL:** <https://forum.babylonjs.com/t/keyboard-camera-rotation-initial-jerk/14965>\
**Category:** Questions\
**Created:** [October 16, 2020, 11:43am UTC](https://forum.babylonjs.com/t/keyboard-camera-rotation-initial-jerk/14965 "2020-10-16T11:43:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ssfrostss](https://avatars.discourse-cdn.com/v4/letter/s/db5fbb/32.png) [@ssfrostss](https://forum.babylonjs.com/u/ssfrostss)\
**Post date:** [October 16, 2020, 11:43am UTC](https://forum.babylonjs.com/t/keyboard-camera-rotation-initial-jerk/14965/1 "2020-10-16T11:43:37Z")

</div>

Hi, everyone. I have a following problem. I try to rotate the camera with cameraRotation via keyboard. But when I hold the button down rotation starts with an initial jerk and only after half a second starts to rotate smoothly. What I’m doing wrong? Here is basic PG link [Babylon.js Playground](https://www.babylonjs-playground.com/#0ZVLJQ)

---

<div class="post-metadata">

**Author:** ![JCPalmer](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/jcpalmer/32/42_2.png) [@JCPalmer](https://forum.babylonjs.com/u/JCPalmer)\
**Post date:** [October 16, 2020, 3:32pm UTC](https://forum.babylonjs.com/t/keyboard-camera-rotation-initial-jerk/14965/2 "2020-10-16T15:32:23Z")

</div>

Do not think you are doing anything wrong, per se. That is just kind of the way it is for typing. Hold down a key, and you get an immediate character, then a pause before it goes into rapid repeat mode. This is to avoid accidental multiple characters, which would get people out with pitch forks.

This is done at a very low level.

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [October 16, 2020, 4:57pm UTC](https://forum.babylonjs.com/t/keyboard-camera-rotation-initial-jerk/14965/3 "2020-10-16T16:57:38Z")

</div>

You can use the keydown/keyup events to get rid of the auto-repeat delay:

[https://www.babylonjs-playground.com/#0ZVLJQ#1](https://www.babylonjs-playground.com/#0ZVLJQ#1)

---

<div class="post-metadata">

**Author:** ![ssfrostss](https://avatars.discourse-cdn.com/v4/letter/s/db5fbb/32.png) [@ssfrostss](https://forum.babylonjs.com/u/ssfrostss)\
**Post date:** [October 19, 2020, 1:55pm UTC](https://forum.babylonjs.com/t/keyboard-camera-rotation-initial-jerk/14965/4 "2020-10-19T13:55:25Z")

</div>

I would say this inspired my solution. And it totally works in playground.
