// compute a circle point in 3D view
std::shared_ptr<GeomDataAPI_Point2D> aCenterAttr = std::dynamic_pointer_cast<
GeomDataAPI_Point2D>(data()->attribute(CENTER_ID()));
- AttributeDoublePtr aRadiusAttr =
+ AttributeDoublePtr aRadiusAttr =
std::dynamic_pointer_cast<ModelAPI_AttributeDouble>(data()->attribute(RADIUS_ID()));
if (aCenterAttr->isInitialized() && aRadiusAttr->isInitialized()) {
std::shared_ptr<GeomAPI_Pnt> aCenter(aSketch->to3D(aCenterAttr->x(), aCenterAttr->y()));
// compute a circle point in 3D view
std::shared_ptr<GeomDataAPI_Point2D> aCenterAttr = std::dynamic_pointer_cast<
GeomDataAPI_Point2D>(data()->attribute(CENTER_ID()));
- AttributeDoublePtr aRadiusAttr =
+ AttributeDoublePtr aRadiusAttr =
std::dynamic_pointer_cast<ModelAPI_AttributeDouble>(attribute(RADIUS_ID()));
if (aCenterAttr->isInitialized() && aRadiusAttr->isInitialized()) {
std::shared_ptr<GeomAPI_Pnt> aCenter(aSketch->to3D(aCenterAttr->x(), aCenterAttr->y()));
if (aCircleShape && aRadius != 0) {
std::list<std::shared_ptr<GeomAPI_Shape> > aShapes;
// make a visible point
- std::shared_ptr<GeomAPI_Shape> aCenterPointShape =
+ std::shared_ptr<GeomAPI_Shape> aCenterPointShape =
GeomAlgoAPI_PointBuilder::vertex(aCenter);
aShapes.push_back(aCenterPointShape);
aShapes.push_back(aCircleShape);
bool SketchPlugin_Circle::isFeatureValid()
{
- std::shared_ptr<GeomDataAPI_Point2D> aCenter =
+ std::shared_ptr<GeomDataAPI_Point2D> aCenter =
std::dynamic_pointer_cast<GeomDataAPI_Point2D>(attribute(CENTER_ID()));
bool aValid = aCenter->isInitialized();
if (aSelection && !aSelection->isNull() && aSelection->isEdge()) {
std::shared_ptr<GeomAPI_Edge> anEdge( new GeomAPI_Edge(aSelection));
std::shared_ptr<GeomAPI_Circ> aCirc = anEdge->circle();
- std::shared_ptr<GeomDataAPI_Point2D> aCenterAttr =
+ std::shared_ptr<GeomDataAPI_Point2D> aCenterAttr =
std::dynamic_pointer_cast<GeomDataAPI_Point2D>(attribute(CENTER_ID()));
aCenterAttr->setValue(sketch()->to2D(aCirc->center()));
real(RADIUS_ID())->setValue(aCirc->radius());
std::shared_ptr<GeomDataAPI_Point2D> aCenterAttr = std::dynamic_pointer_cast<
GeomDataAPI_Point2D>(data()->attribute(CENTER_ID()));
- AttributeDoublePtr aRadiusAttr =
+ AttributeDoublePtr aRadiusAttr =
std::dynamic_pointer_cast<ModelAPI_AttributeDouble>(data()->attribute(RADIUS_ID()));
if (aNbInitialized == 1)
std::dynamic_pointer_cast<GeomDataAPI_Point2D>(attribute(CENTER_ID()));
if (!aCenterAttr->isInitialized())
return;
- AttributeDoublePtr aRadiusAttr =
+ AttributeDoublePtr aRadiusAttr =
std::dynamic_pointer_cast<ModelAPI_AttributeDouble>(attribute(RADIUS_ID()));
if (!aRadiusAttr->isInitialized())
return;