Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Found a solution:

    var imageTopic = new ROSLIB.Topic({
    ros : ros,
    name : '/camera/image/compressed',
    messageType : 'sensor_msgs/CompressedImage'
});

the compressed image can be retrieved via:

var imagedata = "data:image/jpg;base64," + message.data;

Found a solution:

 var imageTopic = new ROSLIB.Topic({
    ros : ros,
    name : '/camera/image/compressed',
    messageType : 'sensor_msgs/CompressedImage'
});

the compressed image can be retrieved via:

var imagedata = "data:image/jpg;base64," + message.data;