Consider this situation: I have a camera node publishing images, and a node that processes the image to get some information (e.g., features). I want to show the processed information over the original image.
For this, a simple solution is to have an image publisher that assembles publishes a debug image when it has any subscribers.
The problem arrives when I want to debug a third node that further processes the information (e.g. to identify groups of features, or tracking). This node subscribes only to the processed information, it does not receive an image. If I change it to receive images, it will be unsynchronized.
Is there a good and simple way to show information over the original image in this third node?
I know of two ways to do this but neither satisfies me:
Having the second node publish two topics: One simply containing the processed information as before, and another with a custom message containing both the processed information and the original image. If the third node has any subscribers in the debug topic, it will subscribe to the second topic instead. This way it has the right image to use for debug.
Having yet another node consuming images and information, synchronizing it and displaying. This is quite an overkill and I have to change the information message to contain the original seq number or timestamp.
Thanks for any suggestions!
Post score: 0