Skip to content

Commit 47cd605

Browse files
committed
fixed save image crash
1 parent e95d868 commit 47cd605

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

orbbec_camera/src/ob_camera_node.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1659,8 +1659,8 @@ void OBCameraNode::onNewFrameCallback(const std::shared_ptr<ob::Frame> &frame,
16591659
image_msg->step = width * unit_step_size_[stream_index];
16601660
image_msg->header.frame_id = frame_id;
16611661
CHECK(image_publishers_.count(stream_index) > 0);
1662-
image_publishers_[stream_index].publish(std::move(image_msg));
16631662
saveImageToFile(stream_index, image, image_msg);
1663+
image_publishers_[stream_index].publish(std::move(image_msg));
16641664
}
16651665

16661666
void OBCameraNode::publishMetadata(const std::shared_ptr<ob::Frame> &frame,

0 commit comments

Comments
 (0)