From: Philipp Hachtmann Date: Sun, 27 Sep 2015 13:56:08 +0000 (+0200) Subject: plot_hpgl: Cosmetic improvements X-Git-Url: http://gitweb.hachti.de/?p=pdp8.git;a=commitdiff_plain;h=9107854b0bc70913de9757805c976b7442d88178 plot_hpgl: Cosmetic improvements Remove unised variables. Signed-off-by: Philipp Hachtmann --- diff --git a/sw/plot_hpgl/pc/hpgl.c b/sw/plot_hpgl/pc/hpgl.c index 70bb2f8..7c1c151 100644 --- a/sw/plot_hpgl/pc/hpgl.c +++ b/sw/plot_hpgl/pc/hpgl.c @@ -114,9 +114,6 @@ int main(int argc, char ** args){ struct point pen_pos={0,0,1}; - double character_angle=0; - double character_size=40; - struct path * first_path=NULL; struct path * current_path=NULL; @@ -204,8 +201,6 @@ int main(int argc, char ** args){ pen_pos.x=0; pen_pos.y=0; pen_pos.valid=1; - character_angle=0; - character_size=40; pen_state=up; break; diff --git a/sw/plot_hpgl/pc/optimize.c b/sw/plot_hpgl/pc/optimize.c index 5a434d0..c859512 100644 --- a/sw/plot_hpgl/pc/optimize.c +++ b/sw/plot_hpgl/pc/optimize.c @@ -85,12 +85,14 @@ struct path *optimize(struct path *input_list){ struct path *result = NULL; struct path *result_last; struct path *cur, *best; - int i; - +#ifdef DEBUG + int i = 0; +#endif + link_reverse(input_list); - // DBG("link_reverse done\n"); + DBG("link_reverse done\n"); - i=0; +#ifdef DEBUG for (cur = input_list; cur; cur = cur->next) DBG("%4i Input Path (%5.2f,%5.2f) -> (%5.2f,%5.2f)\n", i++, @@ -99,6 +101,7 @@ struct path *optimize(struct path *input_list){ cur->plot_end_point->x, cur->plot_end_point->y ); +#endif while(input_list) { best = NULL;