Hi, very interesting to see things working so well with the XV-11, thanks for raising awareness of that :)
The fact that the map looks consistent clearly suggests that the internal state of the mapping system does not jump in as shown in your screenshots. It is thus very likely that your tf setup is messed up in some way (the trajectory server uses tf for generating the path displayed). You most likely have both hector_mapping generating a map->base_link transform as well as some other node doing the same (AMCL would be a candidate for example). When the trajectory server queries tf for transform data based on a timer, it more or less randomly gets one or the other, resulting in this jagged path. That at least is the most probable cause I see from looking at what you posted.
Originally posted by Stefan Kohlbrecher with karma: 24361 on 2013-05-16
This answer was ACCEPTED on the original site
Post score: 3
Original comments
Comment by AeroR on 2013-05-21:
Thank you for your answer! I looked at my transformation frames, and found out that both hector_mapping and my rosbag were publishing on the /odom topic. Depending on which source had last published onto the topic, the trajectory was either updated correctly or wrongly.
Comment by AeroR on 2013-05-21:
By the way, I solved this by removing all /odom entries from the rosbag file using the method described here: http://answers.ros.org/question/56935/how-to-remove-a-tf-from-a-ros-bag/