Skip to content
This repository was archived by the owner on Mar 30, 2023. It is now read-only.

Commit

Permalink
#33 change to src/centroid.cpp to work with new bh, and add src/Makevars
Browse files Browse the repository at this point in the history
  • Loading branch information
sckott committed Jan 6, 2021
1 parent 4369ba2 commit b883511
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
6 changes: 6 additions & 0 deletions src/Makevars
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
CXX_STD = CXX14

all: clean

clean:
rm -Rf $(SHLIB) $(OBJECTS)
7 changes: 5 additions & 2 deletions src/centroid.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,11 @@ void centroid_single(std::string wkt, T& geom_obj,
unsigned int& outlength,
NumericVector& lat,
NumericVector& lng){

point_type p(0,0,0);

point_type p;
// point_type p(0,0,0)
// boost::geometry::set<0>(point_type,0);
// boost::geometry::set<1>(point_type,0);
try{
boost::geometry::read_wkt(wkt, geom_obj);
boost::geometry::centroid(geom_obj, p);
Expand Down

0 comments on commit b883511

Please sign in to comment.