Thank you for your reply.
so... If the Surftype is GeomAbs_BSplineSurface, this means Face is not a Trimmed Surface? I want to Know: Is a TopoDS_Face a trimmed Surface?
Thanks you
Please read Modeling Data User's guide to understand the concept.
A Face is a *topological* entity which limits *geometrical* entity Surface by adding a boundary represented by a Wire. a Wire is a *topological* entity which is a set of *topological* entities - Edges, which limit *geometrical* curves they lie on.
A face lying on a B-Spline surface must always have an explicit wire (or wires - if a face has holes). The latter may either correspond to some arbitrary contour lying on a surface or bounds of the B-Spline surface. In the latter case the face has NaturalRestriction flag turned on - BRep_Tool::NaturalRestriction (face) should return TRUE.
Wed, 08/31/2005 - 03:59
I type wrong, What I want to know is TopoDS_Face not Geom_BsplineSurface.
Thanks.
Wed, 08/31/2005 - 04:53
TopLoc_Location l;
const Handle(Geom_Surface)& S = BRep_Tool::Surface(Face);
if (!S.IsNull()) {
BRepAdaptor_Surface S(Face,Standard_False);
GeomAbs_SurfaceType SurfType = S.GetType();
switch (SurfType) {
case GeomAbs_BSplineSurface :
printf("this is BSpline Surface");
break;
case OtherSurface... :
break;
}
}
Wed, 08/31/2005 - 09:08
Thank you for your reply.
so... If the Surftype is GeomAbs_BSplineSurface, this means Face is not a Trimmed Surface? I want to Know: Is a TopoDS_Face a trimmed Surface?
Thanks you
Wed, 08/31/2005 - 12:16
const Handle(Geom_Surface)& S = BRep_Tool::Surface(Face);
Handle(Standard_Type) TheType = S->DynamicType();
if ( TheType == STANDARD_TYPE(Geom_Plane)) {
OS << Handle(Geom_Plane)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_CylindricalSurface)) {
OS << Handle(Geom_CylindricalSurface)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_ConicalSurface)) {
OS << Handle(Geom_ConicalSurface)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_SphericalSurface)) {
OS << Handle(Geom_SphericalSurface)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_ToroidalSurface)) {
OS << Handle(Geom_ToroidalSurface)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_SurfaceOfLinearExtrusion)) {
OS << Handle(Geom_SurfaceOfLinearExtrusion)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_SurfaceOfRevolution)) {
OS << Handle(Geom_SurfaceOfRevolution)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_BezierSurface)) {
OS << Handle(Geom_BezierSurface)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_BSplineSurface)) {
OS << Handle(Geom_BSplineSurface)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_RectangularTrimmedSurface)) {
OS << Handle(Geom_RectangularTrimmedSurface)::DownCast(S);
}
else if ( TheType == STANDARD_TYPE(Geom_OffsetSurface)) {
OS << Handle(Geom_OffsetSurface)::DownCast(S);
}
else {
aMsg <<"UNKNOWN SURFACE TYPE" <
Fri, 09/02/2005 - 04:10
Thank you very much. Now I understand. Thank you.
Tue, 09/06/2005 - 20:28
Please read Modeling Data User's guide to understand the concept.
A Face is a *topological* entity which limits *geometrical* entity Surface by adding a boundary represented by a Wire. a Wire is a *topological* entity which is a set of *topological* entities - Edges, which limit *geometrical* curves they lie on.
A face lying on a B-Spline surface must always have an explicit wire (or wires - if a face has holes). The latter may either correspond to some arbitrary contour lying on a surface or bounds of the B-Spline surface. In the latter case the face has NaturalRestriction flag turned on - BRep_Tool::NaturalRestriction (face) should return TRUE.
Hope this helps.
Roman Lygin
Tue, 10/18/2011 - 14:06
very helpful Roman, valuable info... thanks...