Skip to content

Commit 4469c9a

Browse files
committed
thicker lines and cmakefile changes to include dependencies on cerebro messages
1 parent 7358611 commit 4469c9a

4 files changed

Lines changed: 16 additions & 11 deletions

File tree

CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,11 @@ add_executable( keyframe_pose_graph_slam
6767
src/Worlds.cpp
6868
)
6969

70+
71+
# this is needed to indicate this this executable depends on the messages of the pkg.
72+
add_dependencies(keyframe_pose_graph_slam cerebro_generate_messages_cpp)
73+
74+
7075
add_executable( test_disjointset_imp src/test_disjointset.cpp )
7176
add_executable( test_bfs_imp src/test_bfs.cpp )
7277

src/VizPoseGraph.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ void VizPoseGraph::publishNodesAsLineStrip( const vector<Matrix4d>& w_T_ci,
7272
RosMarkerUtils::init_line_marker( marker );
7373

7474
marker.type = visualization_msgs::Marker::LINE_STRIP;
75-
marker.scale.x *= 2;
75+
marker.scale.x = 0.08;
7676
marker.ns = ns;
7777

7878

@@ -113,7 +113,7 @@ void VizPoseGraph::publishNodesAsLineStrip( const vector<Matrix4d>& w_T_ci,
113113
RosMarkerUtils::init_line_marker( marker );
114114

115115
marker.type = visualization_msgs::Marker::LINE_STRIP;
116-
marker.scale.x = 0.02;
116+
marker.scale.x = 0.06;
117117

118118
std_msgs::ColorRGBA C1;
119119
C1.r = r; C1.g=g; C1.b=b; C1.a = 0.8;
@@ -451,7 +451,7 @@ void VizPoseGraph::publishCameraVisualMarker( const Matrix4d& wTc, const string&
451451
RosMarkerUtils::init_camera_marker( marker2, 10 );
452452
RosMarkerUtils::setpose_to_marker( wTc, marker2 );
453453
RosMarkerUtils::setcolor_to_marker( r,g,b, marker2 );
454-
marker2.scale.x = 0.02;
454+
marker2.scale.x = 0.08;
455455
marker2.id = 0;
456456
marker2.ns = ns+string("_cam_visual");
457457
pub_pgraph.publish( marker2 );

src/Worlds.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -305,20 +305,20 @@ void Worlds::disjoint_set_status_image(cv::Mat& im_disp, bool enable_bubbles, bo
305305
{
306306

307307

308-
im_disp = cv::Mat::zeros(cv::Size(400,100), CV_8UC3);
308+
im_disp = cv::Mat::zeros(cv::Size(400,120), CV_8UC3);
309309

310310
if( enable_bubbles ) {
311311
int uu = n_worlds(); //disjoint_set.element_count();
312312
// circles
313-
cv::putText( im_disp, "Worlds:", cv::Point(5, 10), cv::FONT_HERSHEY_SIMPLEX,
314-
0.6, cv::Scalar(255,255,255), 1.5 );
315-
cv::putText( im_disp, "SetIDs of Worlds:", cv::Point(5, 65), cv::FONT_HERSHEY_SIMPLEX,
316-
0.6, cv::Scalar(255,255,255), 1.5 );
313+
cv::putText( im_disp, "Worlds:", cv::Point(5, 20), cv::FONT_HERSHEY_SIMPLEX,
314+
0.9, cv::Scalar(255,255,255), 2. );
315+
cv::putText( im_disp, "SetIDs of Worlds:", cv::Point(5, 80), cv::FONT_HERSHEY_SIMPLEX,
316+
0.9, cv::Scalar(255,255,255), 2. );
317317
for( int i=0 ; i<uu; i++ ) {
318318
// World Colors
319319
cv::Scalar color = FalseColors::randomColor( i );
320320
// cout << color << endl;
321-
cv::Point pt = cv::Point(20*i+15, 30);
321+
cv::Point pt = cv::Point(20*i+15, 35);
322322
cv::circle( im_disp, pt, 10, color, -1 );
323323
cv::putText( im_disp, to_string(i), pt, cv::FONT_HERSHEY_SIMPLEX,
324324
0.4, cv::Scalar(255,255,255), 1.5 );
@@ -327,7 +327,7 @@ void Worlds::disjoint_set_status_image(cv::Mat& im_disp, bool enable_bubbles, bo
327327
// Set Colors
328328
int setId = find_setID_of_world_i( i );
329329
color = FalseColors::randomColor( setId );
330-
pt = cv::Point(20*i+15, 85);
330+
pt = cv::Point(20*i+15, 95);
331331
cv::circle( im_disp, pt, 10, color, -1 );
332332
cv::putText( im_disp, to_string(setId), pt, cv::FONT_HERSHEY_SIMPLEX,
333333
0.4, cv::Scalar(255,255,255), 1.5 );

src/keyframe_pose_graph_slam_node.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,7 @@ void opt_traj_publisher_colored_by_world( const NodeDataManager * manager, const
559559
RosMarkerUtils::init_line_marker( linelist_marker );
560560
linelist_marker.ns = "loopedges_on_opt_traj"; linelist_marker.id = 0;
561561
linelist_marker.color.r = 0.4;linelist_marker.color.g = 0.2;linelist_marker.color.b = 0.;linelist_marker.color.a = 1.;
562-
linelist_marker.scale.x = 0.06;
562+
linelist_marker.scale.x = 0.1;
563563

564564
int nloopedgfes = manager->getEdgeLen();
565565
for( int it=0 ; it<nloopedgfes; it++ ) {

0 commit comments

Comments
 (0)