Warning, /include/opencascade/IntPatch_Point.lxx is written in an unsupported language. File is not indexed.
0001 // Created on: 1992-05-06
0002 // Created by: Jacques GOUSSARD
0003 // Copyright (c) 1992-1999 Matra Datavision
0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS
0005 //
0006 // This file is part of Open CASCADE Technology software library.
0007 //
0008 // This library is free software; you can redistribute it and/or modify it under
0009 // the terms of the GNU Lesser General Public License version 2.1 as published
0010 // by the Free Software Foundation, with special exception defined in the file
0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0012 // distribution for complete text of the license and disclaimer of any warranty.
0013 //
0014 // Alternatively, this file may be used under the terms of Open CASCADE
0015 // commercial license or contractual agreement.
0016
0017 inline IntPatch_Point::IntPatch_Point()
0018 : para(0.0),
0019 tol(0.0),
0020 tgt(false),
0021 mult(false),
0022 onS1(false),
0023 vtxonS1(false),
0024 prm1(0.0),
0025 onS2(false),
0026 vtxonS2(false),
0027 prm2(0.0)
0028 {
0029 }
0030
0031 inline void IntPatch_Point::SetValue(const gp_Pnt& Pt)
0032 {
0033 pt.SetValue(Pt);
0034 }
0035
0036 //=================================================================================================
0037
0038 inline void IntPatch_Point::SetValue(const IntSurf_PntOn2S& thePOn2S)
0039 {
0040 pt = thePOn2S;
0041 }
0042
0043 inline void IntPatch_Point::SetTolerance(const double Tol)
0044 {
0045 tol = Tol;
0046 }
0047
0048 inline void IntPatch_Point::SetParameters(const double U1,
0049 const double V1,
0050 const double U2,
0051 const double V2)
0052 {
0053 pt.SetValue(U1, V1, U2, V2);
0054 }
0055
0056 inline void IntPatch_Point::SetParameter(const double Para)
0057 {
0058 para = Para;
0059 }
0060
0061 inline void IntPatch_Point::SetMultiple(const bool IsMult)
0062 {
0063 mult = IsMult;
0064 }
0065
0066 inline const gp_Pnt& IntPatch_Point::Value() const
0067 {
0068 return pt.Value();
0069 }
0070
0071 inline double IntPatch_Point::Tolerance() const
0072 {
0073 return tol;
0074 }
0075
0076 inline double IntPatch_Point::ParameterOnLine() const
0077 {
0078 return para;
0079 }
0080
0081 inline bool IntPatch_Point::IsTangencyPoint() const
0082 {
0083 return tgt;
0084 }
0085
0086 inline void IntPatch_Point::ParametersOnS1(double& U1, double& V1) const
0087 {
0088 pt.ParametersOnS1(U1, V1);
0089 }
0090
0091 inline void IntPatch_Point::ParametersOnS2(double& U2, double& V2) const
0092 {
0093 pt.ParametersOnS2(U2, V2);
0094 }
0095
0096 inline bool IntPatch_Point::IsMultiple() const
0097 {
0098 return mult;
0099 }
0100
0101 inline bool IntPatch_Point::IsOnDomS1() const
0102 {
0103 return onS1;
0104 }
0105
0106 inline bool IntPatch_Point::IsVertexOnS1() const
0107 {
0108 return vtxonS1;
0109 }
0110
0111 inline const occ::handle<Adaptor3d_HVertex>& IntPatch_Point::VertexOnS1() const
0112 {
0113 if (!vtxonS1)
0114 {
0115 throw Standard_DomainError();
0116 }
0117 return vS1;
0118 }
0119
0120 inline const occ::handle<Adaptor2d_Curve2d>& IntPatch_Point::ArcOnS1() const
0121 {
0122 if (!onS1)
0123 {
0124 throw Standard_DomainError();
0125 }
0126 return arcS1;
0127 }
0128
0129 inline const IntSurf_Transition& IntPatch_Point::TransitionLineArc1() const
0130 {
0131 if (!onS1)
0132 {
0133 throw Standard_DomainError();
0134 }
0135 return traline1;
0136 }
0137
0138 inline const IntSurf_Transition& IntPatch_Point::TransitionOnS1() const
0139 {
0140 if (!onS1)
0141 {
0142 throw Standard_DomainError();
0143 }
0144 return tra1;
0145 }
0146
0147 inline double IntPatch_Point::ParameterOnArc1() const
0148 {
0149 if (!onS1)
0150 {
0151 throw Standard_DomainError();
0152 }
0153 return prm1;
0154 }
0155
0156 inline bool IntPatch_Point::IsOnDomS2() const
0157 {
0158 return onS2;
0159 }
0160
0161 inline bool IntPatch_Point::IsVertexOnS2() const
0162 {
0163 return vtxonS2;
0164 }
0165
0166 inline const occ::handle<Adaptor3d_HVertex>& IntPatch_Point::VertexOnS2() const
0167 {
0168 if (!vtxonS2)
0169 {
0170 throw Standard_DomainError();
0171 }
0172 return vS2;
0173 }
0174
0175 inline const occ::handle<Adaptor2d_Curve2d>& IntPatch_Point::ArcOnS2() const
0176 {
0177 if (!onS2)
0178 {
0179 throw Standard_DomainError();
0180 }
0181 return arcS2;
0182 }
0183
0184 inline const IntSurf_Transition& IntPatch_Point::TransitionLineArc2() const
0185 {
0186 if (!onS2)
0187 {
0188 throw Standard_DomainError();
0189 }
0190 return traline2;
0191 }
0192
0193 inline const IntSurf_Transition& IntPatch_Point::TransitionOnS2() const
0194 {
0195 if (!onS2)
0196 {
0197 throw Standard_DomainError();
0198 }
0199 return tra2;
0200 }
0201
0202 inline double IntPatch_Point::ParameterOnArc2() const
0203 {
0204 if (!onS2)
0205 {
0206 throw Standard_DomainError();
0207 }
0208 return prm2;
0209 }
0210
0211 inline const IntSurf_PntOn2S& IntPatch_Point::PntOn2S() const
0212 {
0213 return pt;
0214 }
0215
0216 inline void IntPatch_Point::Parameters(double& U1, double& V1, double& U2, double& V2) const
0217 {
0218 pt.Parameters(U1, V1, U2, V2);
0219 }