FirstPerson controls horizontal constraint

I use FirstPerson controls for my project and I use constranVertical to limit camera vertical movement, but I also want to use constranHorizontal to limit horizontal rotation like minAzimuthAngle and maxAzimuthAngle in Orbit Controls.
Can I manually set some camera limitations in render loop, or change FirstPerson controls to support this feature. Or even use another controls, which act just like FirstPerson with limitations?

Are you talking about FirstPersonControls or PointerLockControls? I’m asking since the screenshot is from the pointer lock example:

Notice that PointerLockControls captures the mouse cursor. Is that something you need in your app?

Nope, It’s just an example representing 3D space for better understanding of my question. I use exactly FirstPersonControls

1 Like