Path.Area: wire sorting fix and improvement

Wire sorting no longer uses libarea. Performance improvement using
boost::geometry::rtree
This commit is contained in:
Zheng, Lei
2017-03-22 04:47:38 +08:00
committed by wmayer
parent a63d293bee
commit 0bd03b9e8b
8 changed files with 435 additions and 384 deletions

View File

@@ -56,8 +56,8 @@ FeatureShape::FeatureShape()
{
ADD_PROPERTY(Sources,(0));
ADD_PROPERTY_TYPE(StartPoint,(Base::Vector3d()),"Path",App::Prop_None,"Path start position");
PARAM_PROP_ADD("Path",AREA_PARAMS_PATH_CONF);
PARAM_PROP_SET_ENUM(Enums,AREA_PARAMS_PATH_CONF);
PARAM_PROP_ADD("Path",AREA_PARAMS_PATH);
PARAM_PROP_SET_ENUM(Enums,AREA_PARAMS_PATH);
}
FeatureShape::~FeatureShape()
@@ -86,12 +86,7 @@ App::DocumentObjectExecReturn *FeatureShape::execute(void)
shapes.push_back(shape);
}
AreaParams params;
#define AREA_PROP_GET(_param) \
params.PARAM_FNAME(_param) = PARAM_FNAME(_param).getValue();
PARAM_FOREACH(AREA_PROP_GET,AREA_PARAMS_PATH_EXTRA)
Area::toPath(path,shapes,&params,&pstart,NULL,PARAM_PROP_ARGS(AREA_PARAMS_PATH));
Area::toPath(path,shapes,&pstart,NULL,PARAM_PROP_ARGS(AREA_PARAMS_PATH));
Path.setValue(path);
return App::DocumentObject::StdReturn;