# Rollercoaster camera stuttering (workshop example)

**URL:** <https://forum.babylonjs.com/t/rollercoaster-camera-stuttering-workshop-example/28572>\
**Category:** Questions\
**Created:** [March 19, 2022, 4:36pm UTC](https://forum.babylonjs.com/t/rollercoaster-camera-stuttering-workshop-example/28572 "2022-03-19T16:36:44Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Coaster](https://avatars.discourse-cdn.com/v4/letter/c/96bed5/32.png) [@Coaster](https://forum.babylonjs.com/u/Coaster)\
**Post date:** [March 19, 2022, 4:36pm UTC](https://forum.babylonjs.com/t/rollercoaster-camera-stuttering-workshop-example/28572/1 "2022-03-19T16:36:44Z")

</div>

I would like to add speed controls to this rollercoaster playground example from the workshop docs:

> **[Babylon.js Playground](https://playground.babylonjs.com/#SQFG0Q%236)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL 3D scenes

I can change the speed of the rollercoaster by modifying line 571:

> var speed = 0.5;

However, the scene begins to stutter when the passenger turns to look out at the start of the run and also on the curve up/down sections. Flat track appears to render smoothly.

What is the cause of this stuttering?

Thank you.

---

<div class="post-metadata">

**Author:** ![Pryme8](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/pryme8/32/7212_2.png) [@Pryme8](https://forum.babylonjs.com/u/Pryme8)\
**Post date:** [March 19, 2022, 4:51pm UTC](https://forum.babylonjs.com/t/rollercoaster-camera-stuttering-workshop-example/28572/2 "2022-03-19T16:51:54Z")

</div>

> **[Babylon.js Playground](https://playground.babylonjs.com/#SQFG0Q%23692)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL 3D scenes

I was lazy on the param names and but that should get you going the right way.

Basically you have to interpolate between your points when you have a speed that is not a whole number.

You will want to fix the camera look at stuff but yeah this is the idea.

---

<div class="post-metadata">

**Author:** ![slin](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/slin/32/36084_2.png) [@slin](https://forum.babylonjs.com/u/slin)\
**Post date:** [March 19, 2022, 4:52pm UTC](https://forum.babylonjs.com/t/rollercoaster-camera-stuttering-workshop-example/28572/3 "2022-03-19T16:52:26Z")

</div>

Hi @Coaster

I guess you need to generate more sections on the curved tracks. The transformation from one point to the next is probably too much. It is more noticeable when the speed is slower. If you can add more sections on the curved tracks, the transformation should be more smooth.

 ![Screen Shot 2022-03-19 at 9.48.39 AM](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/3X/7/f/7f6982e4e09470b0406d8215502b5685e02146f5.jpeg)

---

<div class="post-metadata">

**Author:** ![Coaster](https://avatars.discourse-cdn.com/v4/letter/c/96bed5/32.png) [@Coaster](https://forum.babylonjs.com/u/Coaster)\
**Post date:** [March 20, 2022, 2:57pm UTC](https://forum.babylonjs.com/t/rollercoaster-camera-stuttering-workshop-example/28572/4 "2022-03-20T14:57:14Z")

</div>

Very helpful pointers, thank you both!

I’ll now try to make sense of the workshop guide and figure out how to implement the controls.

> **[Building a Track for a Carriage to Follow | Babylon.js Documentation](https://doc.babylonjs.com/guidedLearning/workshop/Track)**
>
> Study into how to form tracks for a carriage to follow
