I am trying to make a game in space with Newtonian physics. I am trying to make an object (spaceship) increase its rotation speed when WASD keys are pressed. I used a vec3 to represent rotation speed for each axis. My problem is, how to calculate the rotation speed in respect to the coordinate system when I only know the speed I want in relation to my object (spaceship)?
In other words, my player is looking through the object. I want to go rotate left relative to him when he presses A, but I don't know how to calculate it in relation to the universe (coordinate system).