# Best practices for pose/vector transformations

Hello everyone!

This is more of a discussion than a question needing a specific answer. I couldn't find a similar question, so here:

I've written a flight simulator with critical performance constraints: I need it to run as fast as possible.

I need to transform various vectors from one frame to another in each time step.

I use tf::Transform objects to accomplish this a seen here and here, for example. I fill the body_to_mount fields with the required tf data and use multiplication (as here) to transform my data.

I do this because I get the feeling that using tf::TransformListener::rotateVector methods often in my code will slow down my loop time, as the method has to reach out the tf tree, parse it and retrieve the data each time.

What do you think? Am I being paranoid?

edit retag close merge delete