Skip to content

Commit

Permalink
cleanup simplify header.
Browse files Browse the repository at this point in the history
  • Loading branch information
tsteven4 committed Jul 28, 2023
1 parent b1ee6a8 commit 311f952
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
2 changes: 1 addition & 1 deletion smplrout.cc
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ inline bool operator<(const SimplifyRouteFilter::trackerror& lhs, const Simplify
return ((lhs.dist > rhs.dist) || ((lhs.dist == rhs.dist) && (lhs.wptpos < rhs.wptpos)));
}

double SimplifyRouteFilter::compute_track_error(const neighborhood& nb)
double SimplifyRouteFilter::compute_track_error(const neighborhood& nb) const
{
/* if no previous, this is an endpoint and must be preserved. */
if (nb.prev == nullptr) {
Expand Down
10 changes: 2 additions & 8 deletions smplrout.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,7 @@ class SimplifyRouteFilter:public Filter

/* Member Functions */

static void free_xte(struct xte* xte_rec);
void routesimple_waypt_pr(const Waypoint* wpt);
double compute_track_error(const neighborhood& nb);
void compute_xte(struct xte* xte_rec);
static int compare_xte(const void* a, const void* b);
void routesimple_head(const route_head* rte);
void shuffle_xte(struct xte* xte_rec);
double compute_track_error(const neighborhood& nb) const;
void routesimple_tail(const route_head* rte);

/* Data Members */
Expand All @@ -123,6 +117,7 @@ class SimplifyRouteFilter:public Filter
double error = 0;
limit_basis_t limit_basis{limit_basis_t::error};
metric_t metric{metric_t::crosstrack};
int delete_flag{}; // &delete_flag != nullptr

char* countopt = nullptr;
char* erroropt = nullptr;
Expand Down Expand Up @@ -155,7 +150,6 @@ class SimplifyRouteFilter:public Filter
},
};

int delete_flag; // &delete_flag != nullptr
};

#endif // FILTERS_ENABLED
Expand Down

0 comments on commit 311f952

Please sign in to comment.