Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17625

Issues with FPS Camera

$
0
0

Hello! I'm currently working on a 3D camera, and I have it mostly working but I'm having a small issue with rotations.

Basically, when the I rotate the camera to the left, and move forwards, the camera moves towards the right instead of to the left, and vice versa for the right side.

I'm using glm as a maths library, and their quaternions for representing the rotation.

This is the code I use to move the camera.

const float movementSpeed = 200.0F;
const float mouseSensitivity = 10.0F;

m_Camera.Rotate(glm::vec3(0.0F, -Napalm::Input::GetDeltaX() * mouseSensitivity …

Viewing all articles
Browse latest Browse all 17625

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>