You remember a const& to the tf object. This is bad practice. Please take a const TransformsPtr& instead and remember TransformsPtr