File tree Expand file tree Collapse file tree 3 files changed +4
-7
lines changed
Expand file tree Collapse file tree 3 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -239,7 +239,7 @@ void Decoder::PublishAndReset() {
239239 cv::extractChannel (image16u, signal, 7 );
240240 // multiply by 32 for visualization purposes
241241 signal_pub_.publish (
242- cv_bridge::CvImage (header, " 16UC1" , signal * 32 ).toImageMsg ());
242+ cv_bridge::CvImage (header, " 16UC1" , signal * 4 ).toImageMsg ());
243243 }
244244 }
245245
Original file line number Diff line number Diff line change @@ -111,11 +111,9 @@ void LidarScan::HardReset() noexcept {
111111 icol = 0 ;
112112 iscan = 0 ;
113113 prev_uid = -1 ;
114- num_valid = 0 ;
115114}
116115
117116void LidarScan::SoftReset (int full_col) noexcept {
118- num_valid = 0 ;
119117 // Reset col (usually to 0 but in the rare case that data jumps forward
120118 // it will be non-zero)
121119 icol = icol % cols ();
@@ -178,9 +176,10 @@ void LidarScan::DecodeColumn(const uint8_t* const col_buf,
178176 if (min_range <= range && range <= max_range) {
179177 xyz = model.ToPoint (range, theta_enc, ipx);
180178 r = xyz.norm (); // we compute range ourselves
181- s16u = pf.px_signal (px_buf);
182- ++num_valid ;
179+ // s16u = pf.px_ambient (px_buf);
180+ // s16u = pf.px_reflectivity(px_buf) ;
183181 }
182+ s16u = pf.px_ambient (px_buf);
184183 }
185184
186185 // Now we set cloud and image data
@@ -224,7 +223,6 @@ void LidarScan::DecodeColumn(const uint8_t* const col_buf,
224223void LidarScan::UpdateCinfo (sensor_msgs::CameraInfo& cinfo) const noexcept {
225224 cinfo.R [0 ] = range_scale;
226225 cinfo.binning_x = iscan;
227- cinfo.binning_y = num_valid;
228226
229227 // Update camera info roi with curr_scan
230228 auto & roi = cinfo.roi ;
Original file line number Diff line number Diff line change @@ -81,7 +81,6 @@ struct LidarScan {
8181 int icol{0 }; // column index
8282 int iscan{0 }; // subscan index
8383 int prev_uid{-1 };
84- int num_valid{0 };
8584 double min_range{};
8685 double max_range{};
8786 double range_scale{};
You can’t perform that action at this time.
0 commit comments