69 message->header.stamp.sec = seconds;
70 message->header.stamp.nanosec = nanoseconds;
75 message->height = height;
76 message->width = width;
77 message->distortion_model =
"plumb_bob";
78 message->d = {0.0, 0.0, 0.0, 0.0, 0.0};
79 message->k = {k.fx, 0.0, k.cx, 0.0, k.fy, k.cy, 0.0, 0.0, 1.0};
80 message->r = {1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0};
81 message->p = {k.fx, 0.0, k.cx, 0.0, 0.0, k.fy, k.cy, 0.0, 0.0, 0.0, 1.0, 0.0};
82 message->binning_x = 0;
83 message->binning_y = 0;
85 message->roi.x_offset = x_offset;
86 message->roi.y_offset = y_offset;
87 message->roi.height = height;
88 message->roi.width = width;
89 message->roi.do_rectify = do_rectify;
105 uint32_t nanoseconds,
108 std::vector<uint8_t> data) {
110 message->header.stamp.sec = seconds;
111 message->header.stamp.nanosec = nanoseconds;
114 message->width = width;
115 message->height = height;
117 message->is_bigendian = 0;
118 message->step = width *
GetChannels() *
static_cast<uint32_t
>(
sizeof(uint8_t));
119 message->data = std::move(data);
bool WriteCameraInfo(int32_t seconds, uint32_t nanoseconds, uint32_t x_offset, uint32_t y_offset, uint32_t height, uint32_t width, float fov, bool do_rectify)