I have an object in my scene that has been rotated. How do I go about translating a global vector into the local space of this rotated object so that they end up being rendered at the same position as the global vector?
Let's say I have a cube that has been rotated but is still located at the global origin. Now, I want to draw lines for each global dimension (x, y, z) but I want them to be children of the rotated cube, not part of the global scene. What calculations and implementation steps are needed in three.js to achieve this rotation of vectors so they align correctly?