What time should i use for ros messages?
This is a general question about ROS messages, but for the sake of the question i will use point clouds.
Lets say my lidar obtains a point cloud at time t=0 sec.
Now i do some processing on the point cloud (apply some transforms and filtering) and my code returns the modified point cloud at time t=1 sec (time delay due to processing exaggerated). For my first cloud the header time reads "0 sec" should my new cloud (which has been processed) have the current time of publishing (t=1) or the time of the original cloud (t=0)? It is essentially the same cloud but from another perspective but I do not know if placing old times on new messages affects ros looking into the past. Putting the current time is also a problem because by "1s" the transforms could have changed and any further processing would be offset in time.
If anyone could share their insight it would be much appreciated