This commit adds getShape and setShape to TopoShape
This commit is contained in:
committed by
wmayer
parent
5a30a43862
commit
7f4a437cc2
@@ -119,7 +119,7 @@ private:
|
||||
if (pcObjDir)
|
||||
Vector = *static_cast<Base::VectorPy*>(pcObjDir)->getVectorPtr();
|
||||
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->_Shape,Vector);
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->getShape(),Vector);
|
||||
|
||||
Py::List list;
|
||||
list.append(Py::Object(new Part::TopoShapePy(new Part::TopoShape(Alg.V)) , true));
|
||||
@@ -144,7 +144,7 @@ private:
|
||||
if (pcObjDir)
|
||||
Vector = *static_cast<Base::VectorPy*>(pcObjDir)->getVectorPtr();
|
||||
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->_Shape,Vector);
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->getShape(),Vector);
|
||||
|
||||
Py::List list;
|
||||
list.append(Py::Object(new TopoShapePy(new TopoShape(Alg.V)) , true));
|
||||
@@ -177,7 +177,7 @@ private:
|
||||
Base::Vector3d Vector(0,0,1);
|
||||
if (pcObjDir)
|
||||
Vector = static_cast<Base::VectorPy*>(pcObjDir)->value();
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->_Shape,Vector);
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->getShape(),Vector);
|
||||
|
||||
bool hidden = false;
|
||||
if (type && std::string(type) == "ShowHiddenLines")
|
||||
@@ -203,7 +203,7 @@ private:
|
||||
Base::Vector3d Vector(0,0,1);
|
||||
if (pcObjDir)
|
||||
Vector = static_cast<Base::VectorPy*>(pcObjDir)->value();
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->_Shape,Vector);
|
||||
ProjectionAlgos Alg(pShape->getTopoShapePtr()->getShape(),Vector);
|
||||
|
||||
bool hidden = false;
|
||||
if (type && std::string(type) == "ShowHiddenLines")
|
||||
|
||||
@@ -74,7 +74,7 @@ App::DocumentObjectExecReturn *FeatureProjection::execute(void)
|
||||
return new App::DocumentObjectExecReturn("No object linked");
|
||||
if (!link->getTypeId().isDerivedFrom(Part::Feature::getClassTypeId()))
|
||||
return new App::DocumentObjectExecReturn("Linked object is not a Part object");
|
||||
const TopoDS_Shape& shape = static_cast<Part::Feature*>(link)->Shape.getShape()._Shape;
|
||||
const TopoDS_Shape& shape = static_cast<Part::Feature*>(link)->Shape.getShape().getShape();
|
||||
if (shape.IsNull())
|
||||
return new App::DocumentObjectExecReturn("Linked shape object is empty");
|
||||
|
||||
|
||||
@@ -103,7 +103,7 @@ App::DocumentObjectExecReturn *FeatureViewPart::execute(void)
|
||||
return new App::DocumentObjectExecReturn("No object linked");
|
||||
if (!link->getTypeId().isDerivedFrom(Part::Feature::getClassTypeId()))
|
||||
return new App::DocumentObjectExecReturn("Linked object is not a Part object");
|
||||
TopoDS_Shape shape = static_cast<Part::Feature*>(link)->Shape.getShape()._Shape;
|
||||
TopoDS_Shape shape = static_cast<Part::Feature*>(link)->Shape.getShape().getShape();
|
||||
if (shape.IsNull())
|
||||
return new App::DocumentObjectExecReturn("Linked shape object is empty");
|
||||
Base::Vector3d Dir = Direction.getValue();
|
||||
|
||||
@@ -181,7 +181,7 @@ private:
|
||||
if (!link->getTypeId().isDerivedFrom(Part::Feature::getClassTypeId())) {
|
||||
throw Py::TypeError("Linked object is not a Part object");
|
||||
}
|
||||
TopoDS_Shape shape = static_cast<Part::Feature*>(link)->Shape.getShape()._Shape;
|
||||
TopoDS_Shape shape = static_cast<Part::Feature*>(link)->Shape.getShape().getShape();
|
||||
if (!shape.IsNull()) {
|
||||
Base::Vector3d dir = view->Direction.getValue();
|
||||
bool hidden = view->ShowHiddenLines.getValue();
|
||||
|
||||
Reference in New Issue
Block a user