Limit camera movement on vertical axis with OrbitControls


How would i go about limiting the vertical rotation of orbit controls to make it function more like a dome or hemisphere? (to prevent the camera from looking underneath objects)

Thanks a lot.

Try configuring OrbitControls.maxPolarAngle like in the following live example:


That did the job! much appreciated. :smile:

thank you so much