Back to home page

EIC code displayed by LXR

 
 

    


Warning, /include/opencascade/BRepGProp_Face.lxx is written in an unsupported language. File is not indexed.

0001 // Created on: 2005-12-20
0002 // Created by: Sergey KHROMOV
0003 // Copyright (c) 2005-2014 OPEN CASCADE SAS
0004 //
0005 // This file is part of Open CASCADE Technology software library.
0006 //
0007 // This library is free software; you can redistribute it and/or modify it under
0008 // the terms of the GNU Lesser General Public License version 2.1 as published
0009 // by the Free Software Foundation, with special exception defined in the file
0010 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0011 // distribution for complete text of the license and disclaimer of any warranty.
0012 //
0013 // Alternatively, this file may be used under the terms of Open CASCADE
0014 // commercial license or contractual agreement.
0015 
0016 #include <BRep_Tool.hxx>
0017 
0018 //=======================================================================
0019 //function : BRepGProp_Face
0020 //purpose  : Constructor. Initializes the object with IsUseSpan.
0021 //=======================================================================
0022 
0023 inline BRepGProp_Face::BRepGProp_Face(const Standard_Boolean IsUseSpan)
0024      : mySReverse (Standard_False),
0025        myIsUseSpan(IsUseSpan)
0026 {
0027 }
0028 
0029 //=======================================================================
0030 //function : BRepGProp_Face
0031 //purpose  : Constructor.Initializes the object with the face and
0032 //           IsUseSpan flan.
0033 //=======================================================================
0034 
0035 inline BRepGProp_Face::BRepGProp_Face(const TopoDS_Face      &F,
0036                                       const Standard_Boolean  IsUseSpan)
0037      : myIsUseSpan(IsUseSpan)
0038 {
0039   Load(F);
0040 }
0041 
0042 //=======================================================================
0043 //function : NaturalRestriction
0044 //purpose  : Returns Standard_True if the face is not trimmed.
0045 //=======================================================================
0046 
0047 inline Standard_Boolean BRepGProp_Face::NaturalRestriction() const
0048 {
0049   return BRep_Tool::NaturalRestriction(mySurface.Face());
0050 }
0051 //
0052 //=======================================================================
0053 //function : GetFace
0054 //purpose  : Returns TopoDS Face.
0055 //=======================================================================
0056 
0057 inline const TopoDS_Face& BRepGProp_Face::GetFace() const
0058 {
0059   return mySurface.Face();
0060 }
0061 
0062 //=======================================================================
0063 //function : Value2d
0064 //purpose  : Returns the value of the boundary curve of the face.
0065 //=======================================================================
0066 
0067 inline gp_Pnt2d BRepGProp_Face::Value2d(const Standard_Real U) const
0068 {
0069   return myCurve.Value(U);
0070 }
0071 
0072 //=======================================================================
0073 //function : D12d
0074 //purpose  : Returns the point of parameter U and the first derivative
0075 //           at this point of a boundary curve.
0076 //=======================================================================
0077 
0078 inline void BRepGProp_Face::D12d(const Standard_Real  U,
0079                                        gp_Pnt2d      &P,
0080                                        gp_Vec2d      &V1) const
0081 {
0082   myCurve.D1(U,P,V1);
0083 }
0084 
0085 //=======================================================================
0086 //function : FirstParameter
0087 //purpose  : Returns the parametric value of the start point of
0088 //           the current arc of curve.
0089 //=======================================================================
0090 
0091 inline Standard_Real BRepGProp_Face::FirstParameter() const
0092 {
0093   return myCurve.FirstParameter();
0094 }
0095 
0096 //=======================================================================
0097 //function : LastParameter
0098 //purpose  : Returns the parametric value of the end point of
0099 //           the current arc of curve.
0100 //=======================================================================
0101 
0102 inline Standard_Real BRepGProp_Face::LastParameter() const
0103 {
0104   return myCurve.LastParameter();
0105 }