From 1fba8165e61ee1809ce552cea669aa88af641451 Mon Sep 17 00:00:00 2001 From: ehiker Date: Mon, 12 Dec 2011 20:52:55 +0100 Subject: [PATCH] pathplan: added map_2_png as debug view in aalgorithm --- src/pathplan/aalgorithm.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/pathplan/aalgorithm.c b/src/pathplan/aalgorithm.c index 1f8eb323..bd985d9c 100644 --- a/src/pathplan/aalgorithm.c +++ b/src/pathplan/aalgorithm.c @@ -674,6 +674,18 @@ int aAlgorithm_shape(double xstart_real, double ystart_real, double xgoal_real, } } +#ifdef AALGORITHM_DEBUG + char file_name[20]; + sprintf(file_name,"map_x%3d_y%3d_a%1d", coor_contig.x,coor_contig.y, angle_index); + + if(map_2_png(map, file_name)) { + printf("PATHPLAN: aAlgorithm : PNG file sucessfull created"); + } + else { + printf("PATHPLAN: aAlgorithm : PNG file not created!"); + } +#endif + if ((!rot_left) && (!rot_right)) { break; } -- 2.39.2