2003-12-09 14:13 Nadir Bouhamou <nadir.bouhamou@cea.fr>
* src/SMESH/Makefile.in: Correcting a problem araising when
- building the SMESH module whithout Netgen.
+ building the SMESH module without Netgen.
2003-12-09 10:00 Nadir Bouhamou <nadir.bouhamou@cea.fr>
QWTHOME=$d
AC_MSG_RESULT(lib${extension}.so detected in $d/lib)
libqwt_name=${extension}
- dnl break, libqwt-qt4.so is choosen before libqwt.so since it is surely the Qt4 version.
+ dnl break, libqwt-qt4.so is chosen before libqwt.so since it is surely the Qt4 version.
break
fi
done
# compute the mesh
ret = tetra.Compute()
if ret == 0:
- print "probleme when computing the mesh"
+ print "problem when computing the mesh"
else:
- print "Computation succeded"
+ print "Computation succeeded"
src_mesh.Compute()
-# Mesh the box using projection algoritms
+# Mesh the box using projection algorithms
# Define the same global 1D and 2D hypotheses
tgt_mesh = smesh.Mesh(box, "Target mesh")
src_mesh.Triangle()
src_mesh.Compute()
-# Mesh the target mesh using the algoritm Projection1D2D
+# Mesh the target mesh using the algorithm Projection1D2D
tgt_mesh = smesh.Mesh(Face_2, "Target mesh")
tgt_mesh.Projection1D2D().SourceFace(Face_1,src_mesh)
tgt_mesh.Compute()
<b>Add to group</b> box, that allows choosing an existing group for
the created node or element or giving the name to a new group. By
default, the <b>Add to group</b> check box is switched off. If the user
-swiches this check box on, the combo box listing all currently
+switches this check box on, the combo box listing all currently
existing groups of the corresponding type becomes available. By
default, no group is selected. In this case, when the user presses
<b>Apply</b> or <b>Apply & Close</b> button, the warning message box
\page over_constrained_faces_page Over-constrained faces
\n This mesh quality control highlights faces sharing only one border
-with other faces. In other words, the faces having all thier nodes on
+with other faces. In other words, the faces having all their nodes on
the free border of the 2D mesh are highlighted.
\note The highlighted faces are actually over-constrained only if, at
\code
MEFISTO_2D_1 = Mesh_1.Triangle(algo=smeshBuilder.MEFISTO,geom=Face_1)
\endcode
-\n StdMeshers algoritms concerned are <em>REGULAR, PYTHON, COMPOSITE, MEFISTO, Hexa, QUADRANGLE, RADIAL_QUAD</em>.
+\n StdMeshers algorithms concerned are <em>REGULAR, PYTHON, COMPOSITE, MEFISTO, Hexa, QUADRANGLE, RADIAL_QUAD</em>.
\n SMESH Plugins provide such algorithms as: <em> NETGEN, NETGEN_FULL, FULL_NETGEN, NETGEN_1D2D3D, NETGEN_1D2D, NETGEN_2D, NETGEN_3D</em>.
\n If you use DISTENE plugins, you also have <em>BLSURF, GHS3D, GHS3DPRL, Hexotic</em>.
* \param internalPoints - points dividing a grid into parts along an axis
* \param axis - index of an axis counterd from zero, i.e. 0==X, 1==Y, 2==Z
*
- * Parameter t of spaceFunction f(t) is a position [0,1] withing bounding box of
- * the shape to mesh or withing an interval defined by internal points
+ * Parameter t of spaceFunction f(t) is a position [0,1] within bounding box of
+ * the shape to mesh or within an interval defined by internal points
*/
void SetGridSpacing(in SMESH::string_array spaceFunctions,
in SMESH::double_array internalPoints,
Filter CreateFilter();
/*!
- * Load filter library. If libary does not exist it is created
+ * Load filter library. If library does not exist it is created
*/
FilterLibrary LoadLibrary( in string aFileName );
/*!
* Return true if a hypothesis has parameters.
*
- * This method is intended for GUI to know if "Edit" menu item sould be available
+ * This method is intended for GUI to know if "Edit" menu item should be available
*/
boolean HasParameters();
};
};
/*!
- * Auxilary flags for advanced extrusion.
+ * Auxiliary flags for advanced extrusion.
* BOUNDARY: create or not boundary for result of extrusion
* SEW: try to use existing nodes or create new nodes in any case
*/
raises (SALOME::SALOME_Exception);
/*!
- * Get geom shape to mesh. A result sould not be nil. Use HasShapeToMesh()
+ * Get geom shape to mesh. A result should not be nil. Use HasShapeToMesh()
* to know if a returned shape
*/
GEOM::GEOM_Object GetShapeToMesh()
* Get the subMesh object associated to a Sub-shape. The subMesh object
* gives access to nodes and elements IDs.
* SubMesh will be used instead of Sub-shape in a next idl version to
- * adress a specific subMesh...
+ * address a specific subMesh...
*/
SMESH_subMesh GetSubMesh(in GEOM::GEOM_Object aSubObject, in string name)
raises (SALOME::SALOME_Exception);
void ClearLastCreated() raises (SALOME::SALOME_Exception);
/*!
- * \brief Returns description of an error/warning occured during the last operation
+ * \brief Returns description of an error/warning occurred during the last operation
*/
ComputeError GetLastError() raises (SALOME::SALOME_Exception);
ERR_LOADV_COMPUTE_PARAMS, // cant compute point parameters
// Apply(shape)
ERR_APPL_NOT_LOADED, // pattern was not loaded
- ERR_APPL_BAD_DIMENTION, // wrong shape dimention
+ ERR_APPL_BAD_DIMENTION, // wrong shape dimension
ERR_APPL_BAD_NB_VERTICES, // keypoints - vertices mismatch
// Apply(face)
ERR_APPLF_BAD_TOPOLOGY, // bad pattern topology
// +-----+------+ +-----+------+
// | | | |
// | | | |
- // result sould be 2 in both cases
+ // result should be 2 in both cases
//
int aResult0 = 0, aResult1 = 0;
// last node, it is a medium one in a quadratic edge
for ( ; volItr != volEnd; ++volItr )
if ( (*volItr).second >= nbNode )
nbVol++;
- // face is not free if number of volumes constructed on thier nodes more than one
+ // face is not free if number of volumes constructed on their nodes more than one
return (nbVol < 2);
}
//================================================================================
/*
Class : GroupColor
- Description : Functor for check color of group to whic mesh element belongs to
+ Description : Functor for check color of group to which mesh element belongs to
*/
//================================================================================
/*
Class : GroupColor
- Description : Functor for check color of group to whic mesh element belongs to
+ Description : Functor for check color of group to which mesh element belongs to
*/
class SMESHCONTROLS_EXPORT GroupColor: public virtual Predicate{
public:
}
// Read connectivity between zones. Nodes of the zone interface will be
- // replaced withing the zones read later
+ // replaced within the zones read later
string err = zone.ReadZonesConnection( _fn, cgnsBase, zonesByName, myMesh );
if ( !err.empty() )
addMessage( err );
};
/**
- * @returns \p false when error occured, \p true otherwise.
+ * @returns \p false when error occurred, \p true otherwise.
* Adjusts the \p in_stream to the beginning of the
* dataset \p ds_name.
*/
{
/* find "D" in string, start looking at
* 6th element, to improve speed.
- * We dont expect a "D" earlier
+ * We don't expect a "D" earlier
*/
const size_t position = number.find("D",6);
if ( position != std::string::npos )
#ifndef MED_SliceArray_HeaderFile
#define MED_SliceArray_HeaderFile
-#ifdef WIN32 // for correctly compiling "valarray" in modules, which are includes this file
+#ifdef WIN32 // for correctly compiling "valarray" in modules, which includes this file
#undef max
#undef min
#endif
namespace MED
{
//---------------------------------------------------------------
- //! This class intends to provide an uniform way to handle multy-dimention data (const version)
+ //! This class intends to provide a uniform way to handle multidimensional data (const version)
/*!
- It just contains pointer to real sequence and implement proper calcultion of its indexes.
- This class deal with constant pointer to the sources data and provide const method to
- read the them (data).
+ It just contains a pointer to real sequence and implement proper calculation of its indexes.
+ This class deals with constant pointer to the sources data and provides const method to
+ read them (data).
*/
template<class TValueType>
class TCSlice
{
- const TValueType* myCValuePtr; //!< Reference to source multy-dimension data
- size_t mySourceSize; //!< Size of the source multy-dimension data
+ const TValueType* myCValuePtr; //!< Reference to source multidimensional data
+ size_t mySourceSize; //!< Size of the source multidimensional data
std::slice mySlice; //!< Defines algorithm of index calculation
protected:
throw std::out_of_range("TCSlice::check_id");
}
- //! Calculate internal index to get proper element from the source multy-dimension data
+ //! Calculate internal index to get proper element from the source multidimensional data
size_t
calculate_id(size_t theId) const
{
//---------------------------------------------------------------
- //! This class extend TCSlice functionality for non-constant case
+ //! This class extends TCSlice functionality for non-constant case
template<class TValueType>
class TSlice: public TCSlice<TValueType>
{
virtual TModeSwitchInfo
{
EEntiteMaillage myEntity; //!< Defines the MED Entity where the mesh cells belongs to
- //! Let known what MED ENTITY the cells belong to
+ //! Find out what MED ENTITY the cells belong to
EEntiteMaillage GetEntity() const { return myEntity;}
EGeometrieElement myGeom; //!< Defines the MED Geometric type of the instance
- //! Let known what MED geometrical type the cells belong to
+ //! Find out what MED geometrical type the cells belong to
EGeometrieElement GetGeom() const { return myGeom;}
EConnectivite myConnMode; //!< Defines connectivity mode
- //! Let known in what connectivity the cells are writen
+ //! Find out in what connectivity the cells are written
EConnectivite GetConnMode() const { return myConnMode;}
virtual TInt GetConnDim() const = 0; //!< Gives step in the connectivity sequence
{
//! Defines the MED Entity where the polygons belongs to
EEntiteMaillage myEntity; // MED_FACE|MED_MAILLE
- //! Let known what MED ENTITY the MED Polygons belong to
+ //! Find out what MED ENTITY the MED Polygons belong to
EEntiteMaillage GetEntity() const { return myEntity;}
//! Defines the MED Geometric type of the instance
EGeometrieElement myGeom; // ePOLYGONE
- //! Let known what MED geometrical type the MED Polygons belong to
+ //! Find out what MED geometrical type the MED Polygons belong to
EGeometrieElement GetGeom() const { return ePOLYGONE;}
//! Defines connectivity mode
EConnectivite myConnMode; // eNOD|eDESC(eDESC not used)
- //! Let known in what connectivity the cells are writen
+ //! Find out in what connectivity the cells are written
EConnectivite GetConnMode() const { return myConnMode;}
PElemNum myConn; //!< Table de connectivities
{
//! Defines the MED Entity where the polyedres belongs to
EEntiteMaillage myEntity; // MED_FACE|MED_MAILLE
- //! Let known what MED ENTITY the MED Polyedres belong to
+ //! Find out what MED ENTITY the MED Polyedres belong to
EEntiteMaillage GetEntity() const { return myEntity;}
//! Defines the MED Geometric type of the instance
EGeometrieElement myGeom; // ePOLYEDRE
- //! Let known what MED geometrical type the MED Polyedres belong to
+ //! Find out what MED geometrical type the MED Polyedres belong to
EGeometrieElement GetGeom() const { return ePOLYEDRE;}
//! Defines connectivity mode
EConnectivite myConnMode; // eNOD|eDESC(eDESC not used)
- //! Let known in what connectivity the cells are writen
+ //! Find out in what connectivity the cells are written
EConnectivite GetConnMode() const { return myConnMode;}
PElemNum myConn; //!< Table de connectivities
struct MEDWRAPPER_EXPORT TFieldInfo:
virtual TNameInfo
{
- PMeshInfo myMeshInfo; //!< A reference to correspondig MED Mesh
+ PMeshInfo myMeshInfo; //!< A reference to corresponding MED Mesh
//! Get a reference to corresponding MED Mesh
const PMeshInfo& GetMeshInfo() const { return myMeshInfo;}
- ETypeChamp myType; //!< Defines type of the MED Field
- //! Let known what type of the MED FIELD is used
+ ETypeChamp myType; //!< Defines type of MED Field
+ //! Find out what type of MED FIELD is used
ETypeChamp GetType() const { return myType;}
TInt myNbComp; //!< Defines number of components stored in the field
- //! Get number of components for the MED FIELD
+ //! Get number of components for MED FIELD
TInt GetNbComp() const { return myNbComp;}
EBooleen myIsLocal; //!< Defines if the MED Field is local
- //! Let known is the MED FIELD is local or not
+ //! Find out if MED FIELD is local or not
EBooleen GetIsLocal() const { return myIsLocal;}
- TInt myNbRef; //!< Defines number of refereces of the field
- //! Let known number of references for the MED FIELD
+ TInt myNbRef; //!< Defines number of references of the field
+ //! Find out number of references for the MED FIELD
TInt GetNbRef() const { return myNbRef;}
TString myCompNames; //!< Contains names for each of MED Field components
//! Defines, which geometrical type the MED Gauss entity belongs to
EGeometrieElement myGeom;
- //! Let known what MED geometrical type the MED GAUSS entity belong to
+ //! Find out what MED geometrical type the MED GAUSS entity belong to
EGeometrieElement GetGeom() const { return myGeom;}
//! Contains coordinates for the refereced nodes
//! Defines the MED Entity where the MED TimeStamp belongs to
EEntiteMaillage myEntity;
- //! Let known to what MED Entity the MED TimeStamp belong to
+ //! Find out to what MED Entity the MED TimeStamp belong to
EEntiteMaillage GetEntity() const { return myEntity;}
//! Keeps map of number of cells per geometric type where the MED TimeStamp belongs to
typedef boost::tuple<TKey,TInt> TInfo;
EModeProfil myMode; //!< Keeps mode for the MED Profile
- //! Let known what mode of MED Profile is used
+ //! Find out what mode of MED Profile is used
EModeProfil GetMode() const { return myMode;}
//! Set mode for the MED Profile
void SetMode(EModeProfil theMode) { myMode = theMode;}
//! Set number of mesh elelemts by its order number
void SetElemNum(TInt theId, TInt theVal);
- //! Let known is the MED Profile defined
+ //! Find out if the MED Profile defined
bool IsPresent() const { return GetName() != "";}
- //! Let known size of the MED Profile
+ //! Find out size of the MED Profile
TInt GetSize() const { return (TInt)myElemNum->size();}
};
struct MEDWRAPPER_EXPORT TWrapper
{
typedef boost::mutex TMutex;
- //! This is a syncronization primitive which allow to support thread safety for the MED access
+ //! This is a synchronization primitive which allow to support thread safety for the MED access
TMutex myMutex;
virtual
SMDS_ElemIteratorPtr aNodesIter = anElem->nodesIterator();
{
- // Convertions connectivities from SMDS to VTK
+ // Convert connectivities from SMDS to VTK
if (aType == SMDSAbs_Volume && anElem->IsPoly() && aNbNodes > 3) { // POLYEDRE
anIdList->Reset();
if ( !n1 || !n2 ) return 0;
SMDS_MeshEdge * edge = 0;
- // --- retreive nodes ID
+ // --- retrieve nodes ID
vector<vtkIdType> nodeIds;
nodeIds.clear();
nodeIds.push_back(n1->getVtkId());
SMDS_Mesh();
- //! to retreive this SMDS_Mesh instance from its elements (index stored in SMDS_Elements)
+ //! to retrieve this SMDS_Mesh instance from its elements (index stored in SMDS_Elements)
static std::vector<SMDS_Mesh*> _meshList;
//! actual nodes coordinates, cells definition and reverse connectivity are stored in a vtkUnstructuredGrid
#ifndef _SMDS_TypeOfPosition_HeaderFile
#define _SMDS_TypeOfPosition_HeaderFile
-enum SMDS_TypeOfPosition // Value is equal to shape dimention
+enum SMDS_TypeOfPosition // Value is equal to shape dimension
{
SMDS_TOP_UNSPEC = -1,
SMDS_TOP_VERTEX = 0,
//=============================================================================
/*!
- * Usually an algoritm has nothing to save
+ * Usually an algorithm has nothing to save
*/
//=============================================================================
if ( !fIt->more() )
return MEr_EMPTY;
- // We check that olny links on EDGEs encouter once, the rest links, twice
+ // We check that only links on EDGEs encouter once, the rest links, twice
set< SMESH_TLink > links;
while ( fIt->more() )
{
// ==================================================================
// SMESH_Hypothesis::GetDim();
- // 1 - dimention of target mesh
+ // 1 - dimension of target mesh
bool OnlyUnaryInput() const { return _onlyUnaryInput; }
// 2 - is collection of tesselatable shapes inacceptable as input;
// 3 - is a Dim-1 mesh prerequisite
bool NeedShape() const { return _requireShape; }
- // 4 - is shape existance required
+ // 4 - is shape existence required
bool SupportSubmeshes() const { return _supportSubmeshes; }
// 5 - whether supports submeshes if !NeedDiscreteBoundary()
//=============================================================================
/*!
- * Genarate a new id unique withing this Gen
+ * Genarate a new id unique within this Gen
*/
//=============================================================================
*
* An auxiliary hypothesis is optional, i.e. an algorithm
* can work without it and another hypothesis of the same
- * dimention can be assigned to the shape
+ * dimension can be assigned to the shape
*/
virtual bool IsAuxiliary() const
{ return GetType() == PARAM_ALGO && _param_algo_dim < 0; }
//=============================================================================
/*!
- * Get the SMESH_subMesh object implementation. Dont create it, return null
+ * Get the SMESH_subMesh object implementation. Don't create it, return null
* if it does not exist.
*/
//=============================================================================
//=============================================================================
/*!
- * Get the SMESH_subMesh object implementation. Dont create it, return null
+ * Get the SMESH_subMesh object implementation. Don't create it, return null
* if it does not exist.
*/
//=============================================================================
//=======================================================================
//function : IsNotConformAllowed
-//purpose : check if a hypothesis alowing notconform mesh is present
+//purpose : check if a hypothesis allowing notconform mesh is present
//=======================================================================
bool SMESH_Mesh::IsNotConformAllowed() const
//=======================================================================
//function : GetAncestors
//purpose : return list of ancestors of theSubShape in the order
-// that lower dimention shapes come first.
+// that lower dimension shapes come first.
//=======================================================================
const TopTools_ListOfShape& SMESH_Mesh::GetAncestors(const TopoDS_Shape& theS) const
bool IsUsedHypothesis(SMESHDS_Hypothesis * anHyp,
const SMESH_subMesh * aSubMesh);
/*!
- * \brief check if a hypothesis alowing notconform mesh is present
+ * \brief check if a hypothesis allowing notconform mesh is present
*/
bool IsNotConformAllowed() const;
bool IsMainShape(const TopoDS_Shape& theShape) const;
/*!
* \brief Return list of ancestors of theSubShape in the order
- * that lower dimention shapes come first
+ * that lower dimension shapes come first
*/
const TopTools_ListOfShape& GetAncestors(const TopoDS_Shape& theSubShape) const;
* \brief Reorient faces.
* \param theFaces - the faces to reorient. If empty the whole mesh is meant
* \param theDirection - desired direction of normal of \a theFace
- * \param theFace - one of \a theFaces that sould be oriented according to
+ * \param theFace - one of \a theFaces that should be oriented according to
* \a theDirection and whose orientation defines orientation of other faces
* \return number of reoriented faces.
*/
}
else
{
- // among possible triangles create ones discribed by split method
+ // among possible triangles create ones described by split method
const int* nInd = volTool.GetFaceNodesIndices( iF );
int nbVariants = ( nbNodes == 4 ? 2 : nbNodes );
int iCom = 0; // common node of triangle faces to split into
// Fill theFacets starting from facetID of startHex
- // facets used for seach of volumes adjacent to already treated ones
+ // facets used for searching of volumes adjacent to already treated ones
typedef pair< TFacetOfElem::iterator, int > TElemFacets;
typedef map< TVolumeFaceKey, TElemFacets > TFacetMap;
TFacetMap facetsToCheck;
}
}
if ( maxRatio <= theTgtAspectRatio ) {
- //MESSAGE("-- quality achived --");
+ //MESSAGE("-- quality achieved --");
break;
}
if (it+1 == theNbIterations) {
//=======================================================================
//function : MakeEdgePathPoints
-//purpose : auxilary for ExtrusionAlongTrack
+//purpose : auxiliary for ExtrusionAlongTrack
//=======================================================================
SMESH_MeshEditor::Extrusion_Error
SMESH_MeshEditor::MakeEdgePathPoints(std::list<double>& aPrms,
//=======================================================================
//function : MakeExtrElements
-//purpose : auxilary for ExtrusionAlongTrack
+//purpose : auxiliary for ExtrusionAlongTrack
//=======================================================================
SMESH_MeshEditor::Extrusion_Error
SMESH_MeshEditor::MakeExtrElements(TIDSortedElemSet theElemSets[2],
// remove a linear element
GetMeshDS()->RemoveFreeElement(elem, theSm, /*fromGroups=*/false);
- // remove central nodes of biquadratic elements (biquad->quad convertion)
+ // remove central nodes of biquadratic elements (biquad->quad conversion)
if ( hasCentralNodes )
for ( size_t i = nbNodes * 2; i < nodes.size(); ++i )
if ( nodes[i]->NbInverseElements() == 0 )
// face does not exist
SMESHDS_Mesh* aMesh = GetMeshDS();
- // TODO algoritm not OK with vtkUnstructuredGrid: 2 meshes can't share nodes
+ // TODO algorithm not OK with vtkUnstructuredGrid: 2 meshes can't share nodes
//SMDS_Mesh aTmpFacesMesh; // try to use the same mesh
TIDSortedElemSet faceSet1, faceSet2;
set<const SMDS_MeshElement*> volSet1, volSet2;
// additional nodes are inserted on a link provided that no
// volume elements share the splitted link.
// The side 2 is a free border if theSide2IsFreeBorder == true.
- // Sewing is peformed between the given first, second and last
+ // Sewing is performed between the given first, second and last
// nodes on the sides.
// theBorderFirstNode is merged with theSide2FirstNode.
// if (!theSide2IsFreeBorder) then theSide2SecondNode gives
// Nodes and elements created during last operation
SMESH_SequenceOfElemPtr myLastCreatedNodes, myLastCreatedElems;
- // Description of error/warning occured during last operation
+ // Description of error/warning occurred during last operation
SMESH_ComputeErrorPtr myError;
};
if ( !bestEdge.IsNull() )
{
- // move n12 to position of a successfull projection
+ // move n12 to position of a successful projection
//double tol = BRep_Tool::Tolerance(edges[ iOkEdge ]);
if ( !force3d /*&& distMiddleProj > 2*tol*/ )
{
* of the FACE normal
* \return double - the angle (between -Pi and Pi), negative if the angle is concave,
* 1e100 in case of failure
- * \waring Care about order of the EDGEs and their orientation to be as they are
+ * \warning Care about order of the EDGEs and their orientation to be as they are
* within the FACE! Don't pass degenerated EDGEs neither!
*/
//================================================================================
* \brief Make up a chain of links
* \param iSide - link to add first
* \param chain - chain to fill in
- * \param pos - postion of medium nodes the links should have
+ * \param pos - position of medium nodes the links should have
* \param error - out, specifies what is wrong
* \retval bool - false if valid chain can't be built; "valid" means that links
* of the chain belongs to rectangles bounding hexahedrons
if ( _sideIsAdded[ iSide ]) // already in chain
return true;
- if ( _sides.size() != 4 ) { // triangle - visit all my continous faces
+ if ( _sides.size() != 4 ) { // triangle - visit all my continuous faces
MSGBEG( *this );
TLinkSet links;
list< const QFace* > faces( 1, this );
if ( link->MediumPos() >= pos ) {
int nbLinkFaces = link->_faces.size();
if ( nbLinkFaces == 4 || (/*nbLinkFaces < 4 && */link->OnBoundary())) {
- // hexahedral mesh or boundary quadrangles - goto a continous face
+ // hexahedral mesh or boundary quadrangles - goto a continuous face
if ( const QFace* f = link->GetContinuesFace( this ))
if ( f->_sides.size() == 4 )
return f->GetLinkChain( *chLink, chain, pos, error );
* \brief Move medium node of theLink according to its distance from boundary
* \param theLink - link to fix
* \param theRefVec - movement of boundary
- * \param theLinks - all adjacent links of continous triangles
+ * \param theLinks - all adjacent links of continuous triangles
* \param theFaceHelper - helper is not used so far
* \param thePrevLen - distance from the boundary
* \param theStep - number of steps till movement propagation limit
< const SMDS_MeshElement*, vector< SMDS_ElemIteratorPtr > > TIterOnIter;
SMDS_ElemIteratorPtr faceIter( new TIterOnIter( faceIterVec ));
- // a seacher to check if a volume is close to a concave face
+ // search to check if a volume is close to a concave face
SMESHUtils::Deleter< SMESH_ElementSearcher > faceSearcher
( SMESH_MeshAlgos::GetElementSearcher( *theHelper.GetMeshDS(), faceIter ));
private:
- // Forbiden copy constructor
+ // forbidden copy constructor
SMESH_MesherHelper (const SMESH_MesherHelper& theOther);
// key of a map of bi-quadratic face to it's central node
// ! This is a comment
// NB_POINTS ! 1 integer - the number of points in the pattern.
// X1 Y1 [Z1] ! 2 or 3 reals - nodes coordinates within 2D or 3D domain:
- // X2 Y2 [Z2] ! the pattern dimention is defined by the number of coordinates
+ // X2 Y2 [Z2] ! the pattern dimension is defined by the number of coordinates
// ...
// [ ID1 ID2 ... IDn ] ! Indices of key-points for a 2D pattern (only).
// ! elements description goes after all
// X1 Y1 [Z1] ! 2 or 3 reals - nodes coordinates within 2D or 3D domain:
- // read the first point coordinates to define pattern dimention
+ // read the first point coordinates to define pattern dimension
int dim = readLine( fields, lineBeg, clearFields );
if ( dim == 2 )
myIs2D = true;
if ( nbWires > 1 )
{
// compute UV of inner edge-points using the method for in-face points
- // and devide eList into a list of separate wires
+ // and divide eList into a list of separate wires
bool aBool;
list< list< TopoDS_Edge > > wireList;
list<TopoDS_Edge>::iterator eIt = elIt;
TopAbs_ShapeEnum aType = theShape.ShapeType();
bool dimOk = ( myIs2D ? aType == TopAbs_FACE : aType == TopAbs_SHELL );
if ( !dimOk ) {
- MESSAGE( "Pattern dimention mismatch" );
+ MESSAGE( "Pattern dimension mismatch" );
return setErrorCode( ERR_APPL_BAD_DIMENTION );
}
// Apply(shape)
ERR_APPL_NOT_COMPUTED, // mapping failed
ERR_APPL_NOT_LOADED, // pattern was not loaded
- ERR_APPL_BAD_DIMENTION, // wrong shape dimention
+ ERR_APPL_BAD_DIMENTION, // wrong shape dimension
ERR_APPL_BAD_NB_VERTICES, // keypoints - vertices mismatch
// Apply(face)
ERR_APPLF_BAD_TOPOLOGY, // bad pattern topology
// private methods
struct TPoint {
- gp_XYZ myInitXYZ; // loaded postion
+ gp_XYZ myInitXYZ; // loaded position
gp_XY myInitUV;
double myInitU; // [0,1]
gp_Pnt myXYZ; // position to compute
//=======================================================================
//function : CanAddHypothesis
//purpose : return true if theHypothesis can be attached to me:
-// its dimention is checked
+// its dimension is checked
//=======================================================================
bool SMESH_subMesh::CanAddHypothesis(const SMESH_Hypothesis* theHypothesis) const
case COMPUTE_CANCELED: // nothing to do
break;
case CLEAN:
- cleanDependants(); // clean sub-meshes, dependant on this one, with event CLEAN
+ cleanDependants(); // clean sub-meshes, dependent on this one, with event CLEAN
removeSubMeshElementsAndNodes();
_computeState = NOT_READY;
if ( _algoState == HYP_OK )
//================================================================================
/*!
- * \brief Notify stored event listeners on the occured event
+ * \brief Notify stored event listeners on the occurred event
* \param event - algo_event or compute_event itself
* \param eventType - algo_event or compute_event
* \param hyp - hypothesis, if eventType is algo_event
* \brief Do something on a certain event
* \param event - algo_event or compute_event itself
* \param eventType - algo_event or compute_event
- * \param subMesh - the submesh where the event occures
+ * \param subMesh - the submesh where the event occurs
* \param data - listener data stored in the subMesh
* \param hyp - hypothesis, if eventType is algo_event
*
void setEventListener(EventListener* listener, EventListenerData* data);
/*!
- * \brief Notify stored event listeners on the occured event
+ * \brief Notify stored event listeners on the occurred event
* \param event - algo_event or compute_event itself
* \param eventType - algo_event or compute_event
* \param hyp - hypothesis, if eventType is algo_event
bool CanAddHypothesis(const SMESH_Hypothesis* theHypothesis) const;
// return true if theHypothesis can be attached to me:
- // its dimention is checked
+ // its dimension is checked
static bool IsApplicableHypotesis(const SMESH_Hypothesis* theHypothesis,
const TopAbs_ShapeEnum theShapeType);
* \brief Do something on a certain event
* \param event - algo_event or compute_event itself (of SMESH_subMesh)
* \param eventType - ALGO_EVENT or COMPUTE_EVENT (of SMESH_subMesh)
- * \param subMesh - the submesh where the event occures
+ * \param subMesh - the submesh where the event occurs
* \param data - listener data stored in the subMesh
* \param hyp - hypothesis, if eventType is algo_event
*
/*!
* \brief Set default selection mode
*
-* SLOT called when operation commited. Sets default selection mode
+* SLOT called when operation committed. Sets default selection mode
*/
//================================================================================
void SMESHGUI::onOperationCommited( SUIT_Operation* )
Handle(SALOME_InteractiveObject) io = aSmeshActor->getIO();
if (io->hasEntry())
{
- // entry is "encoded" = it does NOT contain component adress,
+ // entry is "encoded" = it does NOT contain component address,
// since it is a subject to change on next component loading
std::string entry = ip->encodeEntry(io->getEntry(), componentName);
for (std::vector<std::string>::iterator entIt = entries.begin(); entIt != entries.end(); ++entIt)
{
- // entry is a normal entry - it should be "decoded" (setting base adress of component)
+ // entry is a normal entry - it should be "decoded" (setting base address of component)
QString entry (ip->decodeEntry(*entIt).c_str());
// Check that the entry corresponds to a real object in the Study
//================================================================================
/*!
- * \brief detect asigned mesh algorithms
+ * \brief detect assigned mesh algorithms
*/
//================================================================================
//=======================================================================
// function : onProject()
-// purpose : SLOT. Called when state of "Project nodes on ther face"
+// purpose : SLOT. Called when state of "Project nodes on other face"
// checkbox is changed
//=======================================================================
void SMESHGUI_CreatePatternDlg::onProject( bool )
//=======================================================================
void SMESHGUI_CreatePatternDlg::enterEvent( QEvent* )
{
- // there is a stange problem that enterEvent() comes after onSave()
+ // there is a strange problem that enterEvent() comes after onSave()
if ( isVisible () ) {
mySMESHGUI->EmitSignalDeactivateDialog();
setEnabled( true );
//=======================================================================
// name : SMESHGUI_FilterTable::updateAdditionalWidget
-// Purpose : Enable/Disable widget with additonal parameters
+// Purpose : Enable/Disable widget with additional parameters
//=======================================================================
void SMESHGUI_FilterTable::updateAdditionalWidget()
{
//=======================================================================
// name : SMESHGUI_FilterTable::getCompareItem
-// Purpose : Get combo table item for operation of comparision
+// Purpose : Get combo table item for operation of comparison
//=======================================================================
QTableWidgetItem* SMESHGUI_FilterTable::getCompareItem () const
{
{
SMESH::SMESH_GroupBase_var aGrp = *anIter;
if ( CORBA::is_nil( aGrp ) )
- continue; // nonsence
+ continue; // nonsense
SMESH::SMESH_Mesh_var aMesh = aGrp->GetMesh();
if ( CORBA::is_nil( aMesh ) )
if(MYDEBUG) MESSAGE("Loading client meshers plugin library ...");
LibHandle libHandle = LoadLib( aClientLibName.toLatin1().data() );
if (!libHandle) {
- // report any error, if occured
+ // report any error, if occurred
{
#ifdef WIN32
const char* anError = "Can't load client meshers plugin library";
//================================================================================
/*!
* \brief Enable/disable tabs
- * \param int - maximum possible dimention
+ * \param int - maximum possible dimension
*/
//================================================================================
void SMESHGUI_MeshDlg::setMaxHypoDim( const int maxDim )
//================================================================================
/*!
- * \brief SLOT called when a item of Geom selection popup is choosen
+ * \brief SLOT called when a item of Geom selection popup is chosen
*/
//================================================================================
void SMESHGUI_MeshDlg::onGeomPopup( QAction* a )
signals:
void createHyp( const int, const int );
- //!< Emited when "Create hypothesis" button clicked
+ //!< Emitted when "Create hypothesis" button clicked
void editHyp( const int, const int );
- //!< Emited when "Edit hypothesis" button clicked
+ //!< Emitted when "Edit hypothesis" button clicked
void selectAlgo( const int );
- //!< Emited when an algorithm is selected
+ //!< Emitted when an algorithm is selected
private slots:
void onCreateHyp();
/*!
* \brief Selects a recently created mesh or sub-mesh if necessary
*
- * Virtual method redefined from base class called when operation is commited
+ * Virtual method redefined from base class called when operation is committed
* selects a recently created mesh or sub-mesh if necessary. Allows to perform
* selection when the custom selection filters are removed.
*/
//================================================================================
/*!
- * \Brief Returns tab dimention
+ * \Brief Returns tab dimension
* \param tab - the tab in the dlg
* \param dlg - my dialogue
- * \retval int - dimention
+ * \retval int - dimension
*/
//================================================================================
static int getTabDim (const QObject* tab, SMESHGUI_MeshDlg* dlg )
/*!
* \brief Edits mesh or sub-mesh
* \param theMess - Output parameter intended for returning error message
- * \retval bool - TRUE if mesh is edited succesfully, FALSE otherwise
+ * \retval bool - TRUE if mesh is edited successfully, FALSE otherwise
*
* Assigns new name hypotheses and algoriths to the mesh or sub-mesh
*/
*
* method redefined from base class verifies whether given operator is valid for
* this one (i.e. can be started "above" this operator). In current implementation method
- * retuns false if theOtherOp operation is not intended for deleting objects or mesh
+ * returns false if theOtherOp operation is not intended for deleting objects or mesh
* elements.
*/
//================================================================================
for (int i = 0, n = elemPoints->length(); i < n; i++)
aCellsSize += elemPoints[ i ].length();
- // Create unstructured grid and other usefull arrays
+ // Create unstructured grid and other useful arrays
vtkUnstructuredGrid* aGrid = vtkUnstructuredGrid::New();
vtkCellArray* aConnectivity = vtkCellArray::New();
*
* Virtual method redefined from base class verifies whether given operator is valid for
* this one (i.e. can be started "above" this operator). In current implementation method
-* retuns false if theOtherOp operation is not intended for deleting objects or mesh
+* returns false if theOtherOp operation is not intended for deleting objects or mesh
* elements.
*/
bool SMESHGUI_Operation::isValid( SUIT_Operation* theOtherOp ) const
typedef SALOME::GenericObj_wrap<SMESH_IDSource> IDSource_wrap;
/*!
- * \brief Class usefull to convert a string returned from a CORBA call
+ * \brief Class useful to convert a string returned from a CORBA call
* to other string types w/o memory leak.
*
* Usage (of instantiations): QString s = toQStr( objVar->GetName() );
if ( freeMB > 0 && usedMB * 5 > freeMB ) {
bool continu = false;
if ( usedMB * 3 > freeMB )
- // even dont try to show
+ // don't even try to show
SUIT_MessageBox::warning(SMESHGUI::desktop(), QObject::tr("SMESH_WRN_WARNING"),
QObject::tr("SMESH_NO_MESH_VISUALIZATION"));
else
</message>
<message>
<source>SMESH_HYP_9</source>
- <translation>Such dimention hypothesis is already assigned to the shape</translation>
+ <translation>Such dimension hypothesis is already assigned to the shape</translation>
</message>
<message>
<source>SMESH_ID_DIAGONAL</source>
dy *= 1.2;
xSol = 0.5 * (xMax + xMin) ;
ySol = 0.5 * (yMax + yMin) ;
- if ( xMin == 0. && yMin == 0. && xMax == 1. && yMax == 1. ) // avoid infinit loop
+ if ( xMin == 0. && yMin == 0. && xMax == 1. && yMax == 1. ) // avoid infinite loop
{
#ifdef _DEBUG_REFINE_
cout << "SMESH_Block::refineParametersOnFace(): tface.IsUVInQuad() fails" << endl;
if ( saveBetterSolution( sol, theParams, thePoint.SquareDistance( tface.Point( sol ))))
{
#ifdef _DEBUG_REFINE_
- cout << "SMESH_Block::refineParametersOnFace(): dividing suceeded" << endl;
+ cout << "SMESH_Block::refineParametersOnFace(): dividing succeeded" << endl;
cout << " nbGetUV = " << nbGetUV << endl;
#endif
return true;
// TFace, TEdge's and points for that face only
// Note 2: curve adaptors need to have only Value(double), FirstParameter() and
- // LastParameter() defined to be used by Block algoritms
+ // LastParameter() defined to be used by Block algorithms
class SMESHUtils_EXPORT TEdge {
int myCoordInd;
// =============================================================
/*!
- * \brief Contains an algorithm and description of an occured error
+ * \brief Contains an algorithm and description of an occurred error
*/
// =============================================================
outerFace2 = angle2Face.begin()->second;
}
}
- // store the found outer face and add its links to continue seaching from
+ // store the found outer face and add its links to continue searching from
if ( outerFace2 )
{
_outerFaces.insert( outerFace2 );
* \param theRemovedObjIDs - entries of objects whose created commands were removed
* \param theHistoricalDump - true means to keep all commands, false means
* to exclude commands relating to objects removed from study
- * \retval TCollection_AsciiString - Convertion result
+ * \retval TCollection_AsciiString - Conversion result
*/
//================================================================================
* \brief Find algorithm able to create a hypothesis
* \param theGeom - The shape ID the algorithm was created on
* \param theMesh - The mesh ID that created the algorithm
- * \param theHypothesis - The hypothesis the algorithm sould be able to create
+ * \param theHypothesis - The hypothesis the algorithm should be able to create
* \retval Handle(_pyHypothesis) - The found algo
*/
//================================================================================
for ( ; m != fatherMeshes.end(); ++m )
addFatherMesh( *m );
// if ( removedGeom )
- // SetRemovedFromStudy(); // as reffered geometry not in study
+ // SetRemovedFromStudy(); // as referred geometry not in study
}
if ( myGeomNotInStudy )
return;
//================================================================================
/*!
- * \brief clear creation, arg and unkown commands
+ * \brief clear creation, arg and unknown commands
*/
//================================================================================
* \brief additionally to Addition2Creation, clears SetDistrType() command
* \param theCmd - AddHypothesis() command
* \param theMesh - mesh to which a hypothesis is added
- * \retval bool - convertion result
+ * \retval bool - conversion result
*/
//================================================================================
TColStd_SequenceOfAsciiString myArgs; //!< found arguments
TColStd_SequenceOfAsciiString myResults; //!< found results
TColStd_SequenceOfInteger myBegPos; //!< where myRes, myObj, ... begin
- std::list< Handle(_pyCommand) > myDependentCmds; //!< commands that sould follow me in the script
+ std::list< Handle(_pyCommand) > myDependentCmds; //!< commands that should follow me in the script
enum { UNKNOWN=-1, EMPTY=0, RESULT_IND, OBJECT_IND, METHOD_IND, ARG1_IND };
int GetBegPos( int thePartIndex ) const;
lines.push_back( theSavedTrace.SubString( from, to - 1 ));
from = to + 1;
}
- // For the convertion of IDL API calls -> smeshBuilder.py API, "smesh" standing for SMESH_Gen
+ // For the conversion of IDL API calls -> smeshBuilder.py API, "smesh" standing for SMESH_Gen
// was replaces with "smeshgen" (==TPythonDump::SMESHGenName()).
// Change "smesh" -> "smeshgen" in the trace saved before passage to smeshBuilder.py API
bool isNewVersion =
/*
Class : GroupColor_i
- Description : Functor for check color of group to whic mesh element belongs to
+ Description : Functor for check color of group to which mesh element belongs to
*/
GroupColor_i::GroupColor_i()
{
/*
Class : GroupColor_i
- Description : Functor for check color of group to whic mesh element belongs to
+ Description : Functor for check color of group to which mesh element belongs to
*/
class SMESH_I_EXPORT GroupColor_i: public virtual POA_SMESH::GroupColor,
public virtual Predicate_i
LibHandle libHandle = LoadLib( aPlatformLibName.c_str() );
if (!libHandle)
{
- // report any error, if occured
+ // report any error, if occurred
#ifndef WIN32
const char* anError = dlerror();
throw(SALOME_Exception(anError));
if( libname_len > 4 )
libname.resize( libname_len - 4 );
#else
- // PAL17753 (Regresion: missing hypothesis in restored study)
+ // PAL17753 (Regression: missing hypothesis in restored study)
// "lib" also should be removed from the beginning
//if( libname_len > 3 )
//libname.resize( libname_len - 3 );
if( libname_len > 4 )
libname.resize( libname_len - 4 );
#else
- // PAL17753 (Regresion: missing hypothesis in restored study)
+ // PAL17753 (Regression: missing hypothesis in restored study)
// "lib" also should be removed from the beginning
//if( libname_len > 3 )
//libname.resize( libname_len - 3 );
"Groups of Faces", "Groups of Volumes", "Groups of 0D Elements",
"Groups of Balls" };
- // Currently, groups with heterogenous content are not supported
+ // Currently, groups with heterogeneous content are not supported
if ( aType != SMESH::ALL )
{
long aRootTag = GetNodeGroupsTag() + aType - 1;
if ( aMeshSO->_is_nil() || aHypSO->_is_nil())
return false;
- // Find a mesh or submesh refering to theShape
+ // Find a mesh or submesh referring to theShape
SALOMEDS::SObject_wrap aMeshOrSubMesh =
GetMeshOrSubmeshByShape( theStudy, theMesh, theShape );
if ( aMeshOrSubMesh->_is_nil() )
if ( pos < varStr.size() )
{
varFound = ( varStr.compare( pos, myLastParameters[i].size(), myLastParameters[i] ) == 0 &&
- // same string begining but is length same?
+ // same string beginning but is length same?
( pos + myLastParameters[i].size() >= varStr.size() ||
separators.find( varStr[ pos+1 ]) != std::string::npos ));
if ( varFound )
//=============================================================================
/*!
- * \brief Deleter of theNodeSearcher at any compute event occured
+ * \brief Deleter of theNodeSearcher at any compute event occurred
*/
//=============================================================================
//================================================================================
/*!
* \brief Increment mesh modif time and optionally record that the performed
- * modification may influence futher mesh re-compute.
+ * modification may influence further mesh re-compute.
* \param [in] isReComputeSafe - true if the modification does not influence
- * futher mesh re-compute
+ * further mesh re-compute
*/
//================================================================================
* \brief Initialize and return myPreviewMesh
* \param previewElements - type of elements to show in preview
*
- * WARNING: call it once par a method!
+ * WARNING: call it once per method!
*/
//================================================================================
//=======================================================================
/*
- * Returns description of an error/warning occured during the last operation
+ * Returns description of an error/warning occurred during the last operation
* WARNING: ComputeError.code >= 100 and no corresponding enum in IDL API
*/
//=======================================================================
else
pyDump << mesh_var << ", ";
if ( group_var->_is_nil() )
- pyDump << "_NoneGroup = "; // assignment to None is forbiden
+ pyDump << "_NoneGroup = "; // assignment to None is forbidden
else
pyDump << group_var << " = ";
pyDump << this << ".MakeBoundaryMesh( "
else
groupsOfThisMesh[ nbGroups++ ] = groups[i];
if ( SMESH::DownCast<SMESH_Mesh_i*>( groups[i] ))
- THROW_SALOME_CORBA_EXCEPTION("expect a group but recieve a mesh", SALOME::BAD_PARAM);
+ THROW_SALOME_CORBA_EXCEPTION("expected a group but received a mesh", SALOME::BAD_PARAM);
}
groupsOfThisMesh->length( nbGroups );
groupsOfOtherMesh->length( nbGroupsOfOtherMesh );
else
pyDump << mesh_var << ", ";
if ( group_var->_is_nil() )
- pyDump << "_NoneGroup = "; // assignment to None is forbiden
+ pyDump << "_NoneGroup = "; // assignment to None is forbidden
else
pyDump << group_var << " = ";
pyDump << this << ".MakeBoundaryElements( "
*/
void ClearLastCreated() throw (SALOME::SALOME_Exception);
/*!
- * \brief Returns description of an error/warning occured during the last operation
+ * \brief Returns description of an error/warning occurred during the last operation
*/
SMESH::ComputeError* GetLastError() throw (SALOME::SALOME_Exception);
if ( n->NbInverseElements() == 0 )
_impl->GetMeshDS()->RemoveFreeNode( n, /*sm=*/0 );
- TPythonDump pyDump; // Supress dump from RemoveGroup()
+ TPythonDump pyDump; // Suppress dump from RemoveGroup()
// Update Python script (theGroup must be alive for this)
pyDump << SMESH::SMESH_Mesh_var(_this())
if ( !aFile.openForWriting() ) {
msg << "You cannot create the file "
<< aFile.getName()
- << ". Check the directory existance and access rights";
+ << ". Check the directory existence and access rights";
}
aFile.remove();
}
/*!
* \brief Replace parameters of the functions on the Salome NoteBook Variables
* \param theString - Input string
- * \retval TCollection_AsciiString - Convertion result
+ * \retval TCollection_AsciiString - Conversion result
*/
//================================================================================
void SMESH_NoteBook::ReplaceVariables()
* \param theRemovedObjIDs - entries of objects whose created commands were removed
* \param theHistoricalDump - true means to keep all commands, false means
* to exclude commands relating to objects removed from study
- * \retval TCollection_AsciiString - Convertion result
+ * \retval TCollection_AsciiString - Conversion result
*/
static void
ConvertScript(std::list< TCollection_AsciiString >& theScriptLines,
def GetNewNodes(mesh,Elems,OldNodes):
"""
- Auxilary function, which return list of nodes from
+ Auxiliary function, which return list of nodes from
given Elems avoided nodes from OldNodes
"""
newnodes = []
# 0D algorithm
if self.geom is None:
self.geom = store_geom
- raise RuntimeError, "Attemp to create SegmentAroundVertex_0D algoritm on None shape"
+ raise RuntimeError, "Attempt to create SegmentAroundVertex_0D algorithm on None shape"
from salome.smesh.smeshBuilder import AssureGeomPublished, GetName, TreatHypoStatus
AssureGeomPublished( self.mesh, self.geom )
name = GetName(self.geom)
# several functions, they must be accompanied by relative coordinates of
# points dividing the whole shape into ranges where the functions apply; points
# coodrinates should vary within (0.0, 1.0) range. Parameter \a t of the spacing
- # function f(t) varies from 0.0 to 1.0 witin a shape range.
+ # function f(t) varies from 0.0 to 1.0 within a shape range.
# Examples:
# - "10.5" - defines a grid with a constant spacing
# - [["1", "1+10*t", "11"] [0.1, 0.6]] - defines different spacing in 3 ranges.
pass # end of StdMeshersBuilder_Cartesian_3D class
## Defines a stub 1D algorithm, which enables "manual" creation of nodes and
-# segments usable by 2D algoritms
+# segments usable by 2D algorithms
#
# It is created by calling smeshBuilder.Mesh.UseExistingSegments(geom=0)
#
pass # end of StdMeshersBuilder_UseExisting_1D class
## Defines a stub 2D algorithm, which enables "manual" creation of nodes and
-# faces usable by 3D algoritms
+# faces usable by 3D algorithms
#
# It is created by calling smeshBuilder.Mesh.UseExistingFaces(geom=0)
#
def GetMeshOrder(self):
return self.mesh.GetMeshOrder()
- ## Set order in which concurrent sub-meshes sould be meshed
+ ## Set order in which concurrent sub-meshes should be meshed
# @param submeshes list of lists of sub-meshes
# @ingroup l2_construct
def SetMeshOrder(self, submeshes):
## Private method.
def Create(self, mesh, geom, hypo, so="libStdMeshersEngine.so"):
if geom is None and mesh.mesh.HasShapeToMesh():
- raise RuntimeError, "Attemp to create " + hypo + " algorithm on None shape"
+ raise RuntimeError, "Attempt to create " + hypo + " algorithm on None shape"
algo = self.FindAlgorithm(hypo, mesh.smeshpyD)
if algo is None:
algo = mesh.smeshpyD.CreateHypothesis(hypo, so)
def Assign(self, algo, mesh, geom):
from salome.smesh.smeshBuilder import AssureGeomPublished, TreatHypoStatus, GetName
if geom is None and mesh.mesh.HasShapeToMesh():
- raise RuntimeError, "Attemp to create " + algo + " algorithm on None shape"
+ raise RuntimeError, "Attempt to create " + algo + " algorithm on None shape"
self.mesh = mesh
if not geom or geom.IsSame( mesh.geom ):
self.geom = mesh.geom
* \param spaceFunctions - functions defining spacing values at given point on axis
* \param internalPoints - points dividing a grid into parts along each direction
*
- * Parameter t of spaceFunction f(t) is a position [0,1] withing bounding box of
+ * Parameter t of spaceFunction f(t) is a position [0,1] within bounding box of
* the shape to mesh
*/
void SetGridSpacing(std::vector<std::string>& spaceFunctions,
else if ( eMidOut != edges.end() )
edges.splice( edges.end(), edges, edges.begin(), eMidOut );
- // sort nodes accoring to the order of edges
+ // sort nodes according to the order of edges
_Node* orderNodes [20];
//TGeomID orderShapeIDs[20];
size_t nbN = 0;
* \brief Restore nodes on internal vertices of a complex side
* \param event - algo_event or compute_event itself (of SMESH_subMesh)
* \param eventType - ALGO_EVENT or COMPUTE_EVENT (of SMESH_subMesh)
- * \param subMesh - the submesh where the event occures
+ * \param subMesh - the submesh where the event occurs
* \param data - listener data stored in the subMesh
* \param hyp - hypothesis, if eventType is algo_event
*/
if ( side->NbEdges() < 2 )
return StdMeshers_Regular_1D::Compute( aMesh, aShape );
- // update segment lenght computed by StdMeshers_AutomaticLength
+ // update segment length computed by StdMeshers_AutomaticLength
const list <const SMESHDS_Hypothesis * > & hyps = GetUsedHypothesis(aMesh, aShape);
if ( !hyps.empty() ) {
StdMeshers_AutomaticLength * autoLenHyp = const_cast<StdMeshers_AutomaticLength *>
//--------------------------------------------------------------------------------
/*!
* \brief Remove imported mesh and/or groups if needed
- * \param sm - submesh loosing Import algo
+ * \param sm - submesh losing Import algo
* \param data - data holding imported groups
*/
void _Listener::removeSubmesh( SMESH_subMesh* sm, _ListenerData* data )
//--------------------------------------------------------------------------------
/*!
* \brief Clear _ImportData::_n2n.
- * _n2n is usefull within one mesh.Compute() only
+ * _n2n is useful within one mesh.Compute() only
*/
void _Listener::clearN2N( SMESH_Mesh* tgtMesh )
{
bool isDegen = ( _helper->HasDegeneratedEdges() &&
( nn[0] == nn[1] || nn[1] == nn[2] || nn[2] == nn[0] ));
- // It was an attemp to fix a problem of a zero area face whose all nodes
+ // It was an attempt to fix a problem of a zero area face whose all nodes
// are on one staight EDGE. But omitting this face makes a hole in the mesh :(
// if ( !isDegen && allNodesAreOld )
// isDegen = isDegenTria( nn );
if (iCnt>1) {
// \begin{E.A.}
// The current algorithm fails if there is more that one
- // face wich contains triangles ...
+ // face which contains triangles ...
// In that case, replace return by break to try another
// method (coded in "if (iCnt != 1) { ... }")
//
// TODO. there are other ways to find out the source FACE:
- // propagation, topological similarity, ect.
+ // propagation, topological similarity, etc...
// simply try to mesh all not meshed SOLIDs
if ( meshedFaces.empty() )
if ( ! fSM->IsMeshComputed() )
{
// Top EDGEs must be projections from the bottom ones
- // to compute stuctured quad mesh on wall FACEs
+ // to compute structured quad mesh on wall FACEs
// ---------------------------------------------------
const TopoDS_Edge& botE = (*quad)->side[ QUAD_BOTTOM_SIDE ].grid->Edge(0);
const TopoDS_Edge& topE = (*quad)->side[ QUAD_TOP_SIDE ].grid->Edge(0);
std::advance( edge2End, *nbE2 );
if ( *nbE1 == *nbE2 && iW2 >= iW1 )
{
- // rotate edge2 untill coincidence with edge1 in 2D
+ // rotate edge2 until coincides with edge1 in 2D
int i = *nbE2;
bool sameUV = false;
while ( !( sameUV = sameVertexUV( *edge2Beg, face2, 0, v0f1UV, vTolUV )) && --i > 0 )
break;
}
}
- // prepare to the next wire loop
+ // prepare for the next wire loop
edge2Beg = edge2End;
}
edge1Beg = edge1End;
if ( !sm || sm->GetAlgoState() != SMESH_subMesh::NO_ALGO )
return usualMessage; // algo is OK, anything else is KO.
- // Try to find a type of all-dimentional algorithm that would compute the
+ // Try to find a type of all-dimensional algorithm that would compute the
// given sub-mesh if it could be launched before projection
const TopoDS_Shape shape = sm->GetSubShape();
const int shapeDim = SMESH_Gen::GetShapeDim( shape );
//================================================================================
/*!
- * \brief Computes transformation beween two sets of 2D points using
+ * \brief Computes transformation between two sets of 2D points using
* a least square approximation
*
* See "Surface Mesh Projection For Hexahedral Mesh Generation By Sweeping"
//================================================================================
/*!
- * \brief Computes transformation beween two sets of 3D points using
+ * \brief Computes transformation between two sets of 3D points using
* a least square approximation
*
* See "Surface Mesh Projection For Hexahedral Mesh Generation By Sweeping"
/*!
- * \brief Finds transformation beween two sets of 2D points using
+ * \brief Finds transformation between two sets of 2D points using
* a least square approximation
*/
class TrsfFinder2D
bool IsIdentity() const { return ( _trsf.Form() == gp_Identity ); }
};
/*!
- * \brief Finds transformation beween two sets of 3D points using
+ * \brief Finds transformation between two sets of 3D points using
* a least square approximation
*/
class TrsfFinder3D
/*!
* \brief Structure used to temporary remove EventProparatorToEdges from faceSubMesh
* in order to prevent propagation of CLEAN event from FACE to EDGEs during
- * StdMeshers_Projection_1D2D::Compute(). The CLEAN event is emmited by Pattern mapper
+ * StdMeshers_Projection_1D2D::Compute(). The CLEAN event is emitted by Pattern mapper
* and causes removal of faces generated on adjacent FACEs.
*/
struct UnsetterOfEventProparatorToEdges
//================================================================================
/*!
- * \brief Preform projection in case if tgtFace.IsPartner( srcFace ) and in case
+ * \brief Perform projection in case if tgtFace.IsPartner( srcFace ) and in case
* if projection by 3D transformation is possible
*/
//================================================================================
//================================================================================
/*!
- * \brief Preform projection in case if the faces are similar in 2D space
+ * \brief Perform projection in case if the faces are similar in 2D space
*/
//================================================================================
//================================================================================
/*!
- * \brief Preform projection in case of quadrilateral faces
+ * \brief Perform projection in case of quadrilateral faces
*/
//================================================================================
// }
// else
// {
- // // find XY of src node withing the quadrilateral srcFace
+ // // find XY of src node within the quadrilateral srcFace
// if ( !block.ComputeParameters( SMESH_TNodeXYZ( srcNode ),
// tgtNodeOrXY.second, srcFaceBID ))
// return false;
int nbright = (int) uv_e1.size();
int nbleft = (int) uv_e3.size();
- if (quad->nbNodeOut(0) && nbvertic == 2) // this should not occure
+ if (quad->nbNodeOut(0) && nbvertic == 2) // this should not occur
{
// Down edge is out
//
}
// right or left boundary quadrangles
- if (quad->nbNodeOut( QUAD_RIGHT_SIDE ) && nbhoriz == 2) // this should not occure
+ if (quad->nbNodeOut( QUAD_RIGHT_SIDE ) && nbhoriz == 2) // this should not occur
{
int g = 0; // last processed node in the grid
int stop = nbright - 1;
// find node c in the grid, nearest to the b
c = 0;
int near = g;
- if (i == stop - 1) { // up bondary reached
+ if (i == stop - 1) { // up boundary reached
c = quad->uv_grid[nbhoriz*(jup + 1) - 2].node;
near = jup;
} else {
// find node c in the grid, nearest to the b
int near = g;
- if (i == stop + 1) { // down bondary reached
+ if (i == stop + 1) { // down boundary reached
c = quad->uv_grid[nbhoriz*jlow + 1].node;
near = jlow;
}
//=======================================================================
//function : ShiftQuad
-//purpose : auxilary function for computeQuadPref
+//purpose : auxiliary function for computeQuadPref
//=======================================================================
void StdMeshers_Quadrangle_2D::shiftQuad(FaceQuadStruct::Ptr& quad, const int num )
//=======================================================================
//function : calcUV
-//purpose : auxilary function for computeQuadPref
+//purpose : auxiliary function for computeQuadPref
//=======================================================================
static gp_UV calcUV(double x0, double x1, double y0, double y1,
//=======================================================================
//function : calcUV2
-//purpose : auxilary function for computeQuadPref
+//purpose : auxiliary function for computeQuadPref
//=======================================================================
static gp_UV calcUV2(double x, double y,
}
int nnn = Min(nr,nl);
- // auxilary sequence of XY for creation nodes
+ // auxiliary sequence of XY for creation nodes
// in the bottom part of central domain
// Length of UVL and UVR must be == nbv-nnn
TColgp_SequenceOfXY UVL, UVR, UVT;
MapShapeNbElems& aResMap,
bool IsQuadratic)
{
- // Auxilary key in order to keep old variant
+ // Auxiliary key in order to keep old variant
// of meshing after implementation new variant
// for bug 0016220 from Mantis.
bool OldVersion = false;
gp_XY a3 (uv_et.front().u, uv_et.front().v);
int nnn = Min(nr,nl);
- // auxilary sequence of XY for creation of nodes
+ // auxiliary sequence of XY for creation of nodes
// in the bottom part of central domain
// it's length must be == nbv-nnn-1
TColgp_SequenceOfXY UVL;
// * \brief Clean mesh on edges
// * \param event - algo_event or compute_event itself (of SMESH_subMesh)
// * \param eventType - ALGO_EVENT or COMPUTE_EVENT (of SMESH_subMesh)
-// * \param subMesh - the submesh where the event occures
+// * \param subMesh - the submesh where the event occurs
// */
// void ProcessEvent(const int event, const int eventType, SMESH_subMesh* subMesh,
// EventListenerData*, const SMESH_Hypothesis*)
gp_XYZ _normal; // to boundary of solid
vector<gp_XYZ> _pos; // points computed during inflation
- double _len; // length achived with the last inflation step
+ double _len; // length achieved with the last inflation step
double _maxLen; // maximal possible length
double _cosin; // of angle (_normal ^ surface)
double _minAngle; // of _simplices
//const double tgtThick = /*Min( 0.5 * data._geomSize, */data._maxThickness;
// Find shapes needing smoothing; such a shape has _LayerEdge._normal on it's
- // boundry inclined to the shape at a sharp angle
+ // boundary inclined to the shape at a sharp angle
//list< TGeomID > shapesToSmooth;
TopTools_MapOfShape edgesOfSmooFaces;
{
gp_XYZ newPos(0,0,0);
- // get a plane to seach a solution on
+ // get a plane to search a solution on
vector< gp_XYZ > vecs( _simplices.size() + 1 );
size_t i;
{ ////////////////////////////////// NEW
gp_XYZ newPos(0,0,0);
- // get a plane to seach a solution on
+ // get a plane to search a solution on
size_t i;
gp_XYZ center(0,0,0);
vector< double > segLen( L._lEdges.size() );
segLen[0] = 0.0;
- // check if length modification is usefull: look for _LayerEdge's
+ // check if length modification is useful: look for _LayerEdge's
// with length limited due to collisions
bool lenLimited = false;
for ( size_t iLE = 1; ( iLE < L._lEdges.size()-1 && !lenLimited ); ++iLE )
//================================================================================
/*!
- * \brief Tranfer parameters from hypothesis to widgets
+ * \brief Transfer parameters from hypothesis to widgets
*/
//================================================================================
//================================================================================
/*!
- * \brief Tranfer parameters from widgets to hypothesis
+ * \brief Transfer parameters from widgets to hypothesis
*/
//================================================================================
argMinimum( int r ) const
{
// for the first row the minimum value is always 0.0
- // for the other rows the minumum value is the above row's value
+ // for the other rows the minimum value is the above row's value
double val = 0.0;
if ( r > 0 && r < rowCount() )
val = value( r-1, ArgColumn );
argMaximum( int r ) const
{
// for the last row the maximum value is always 1.0
- // for the other rows the maxumum value is the below row's value
+ // for the other rows the maximum value is the below row's value
double val = 1.0;
if ( r >= 0 && r < rowCount()-1 ) {
val = value( r+1, ArgColumn );
//================================================================================
/*!
- * \brief Creates a given nubmer of button labels with given labels (QString's)
+ * \brief Creates a given number of button labels with given labels (QString's)
*/
//================================================================================
//\brief Set grid spacing along the three axes
// \param spaceFunctions - functions defining spacing values at given point on axis
// \param internalPoints - points dividing a grid into parts along each direction
-// Parameter t of spaceFunction f(t) is a position [0,1] withing bounding box of
-// the shape to mesh or withing an interval defined by internal points
+// Parameter t of spaceFunction f(t) is a position [0,1] within bounding box of
+// the shape to mesh or within an interval defined by internal points
//=======================================================================
void StdMeshers_CartesianParameters3D_i::SetGridSpacing(const SMESH::string_array& spaceFunctions,
* \param internalPoints - points dividing a grid into parts along each direction
* \param axis - index of an axis counterd from zero, i.e. 0==X, 1==Y, 2==Z
*
- * Parameter t of spaceFunction f(t) is a position [0,1] withing bounding box of
- * the shape to mesh or withing an interval defined by internal points
+ * Parameter t of spaceFunction f(t) is a position [0,1] within bounding box of
+ * the shape to mesh or within an interval defined by internal points
*/
void SetGridSpacing(const SMESH::string_array& spaceFunctions,
const SMESH::double_array& internalPoints,
self.num=1
self.__selectedMesh=None
- # complex whith QResources: not used
+ # complex with QResources: not used
# The icon are supposed to be located in the $SMESH_ROOT_DIR/share/salome/resources/smesh folder,
# other solution could be in the same folder than this python module file:
# iconfolder=os.path.dirname(os.path.abspath(__file__))
Example 2: [(0,0,0,1,0,0),(50,0,0,0,1,0)]: in addition to the first plane cut, cut through a plane passing by (50,0,0) and normal to the y axis.
Note that the plane size us determined automatically from the size of the geometry in question (using a very big trim size = 100 x length of geometry!)
- OutLvlLst is a list containing integers that represent the inner sectioning level with respect to the original geometry type
- A value of 1 means that the section will provide elements of one level lower than the original type. For exemple a solid sectioned at level 1 will produce faces. A Face sectioned at level 1 will produce edges.
+ A value of 1 means that the section will provide elements of one level lower than the original type. For example a solid sectioned at level 1 will produce faces. A Face sectioned at level 1 will produce edges.
A value of 2 means that a deeper sectioning will be applied. A solid sectioned with level 2 will give faces and edges. A face will give edges and vertices. An edge will give only vertices
The number of elements in this list should be (this is verified in the code) equal to the number of elements in the plane cut list. This is logical.
Example 1: [1]
Example 1: [(0,0,0,1,0,0,5)]: cut along a plane passing through the origin and normal to the x-axis with a trim size of 5
Example 2: [(0,0,0,1,0,0,5),(50,0,0,0,1,0,10)]: in addition to the first plane cut, cut through a plane passing by (50,0,0) and normal to the y axis with a trim size of 10
- OutLvlLst is a list containing integers that represent the inner sectioning level with respect to the original geometry type
- A value of 1 means that the section will provide elements of one level lower than the original type. For exemple a solid sectioned at level 1 will produce faces. A Face sectioned at level 1 will produce edges.
+ A value of 1 means that the section will provide elements of one level lower than the original type. For example a solid sectioned at level 1 will produce faces. A Face sectioned at level 1 will produce edges.
A value of 2 means that a deeper sectioning will be applied. A solid sectioned with level 2 will give faces and edges. A face will give edges and vertices. An edge will give only vertices
The number of elements in this list should be (this is verified in the code) equal to the number of elements in the plane cut list. This is logical.
Example 1: [1]
<property name="toolTip">
<string>This parameter allows the user to prescribe a maximal size hmax
for the mesh elements i.e., the lengths of the edges with respect to the specified
- size map. The corresponding values are either relative or absolute depending on the choosen parameter.
+ size map. The corresponding values are either relative or absolute depending on the chosen parameter.
The default values are automatically set based on the surface geometry (curvature dependent) and its
bounding box size.
Please note that, as it is not strictly possible to obey the given or computed size map, the actual maximal
<property name="toolTip">
<string>This parameter allows the user to prescribe a maximal size hmax
for the mesh elements i.e., the lengths of the edges with respect to the specified
- size map. The corresponding values are either relative or absolute depending on the choosen parameter.
+ size map. The corresponding values are either relative or absolute depending on the chosen parameter.
The default values are automatically set based on the surface geometry (curvature dependent) and its
bounding box size.
Please note that, as it is not strictly possible to obey the given or computed size map, the actual maximal
self.num=1
self.__selectedMesh=None
- # complex whith QResources: not used
+ # complex with QResources: not used
# The icon are supposed to be located in the $SMESH_ROOT_DIR/share/salome/resources/smesh folder,
# other solution could be in the same folder than this python module file:
# iconfolder=os.path.dirname(os.path.abspath(__file__))
</size>
</property>
<property name="toolTip">
- <string>Clear all paramters</string>
+ <string>Clear all parameters</string>
</property>
<property name="text">
<string>Reset</string>
</size>
</property>
<property name="toolTip">
- <string>file adress (ex: /home/A123456/cracked.med)</string>
+ <string>file address (ex: /home/A123456/cracked.med)</string>
</property>
<property name="autoFillBackground">
<bool>true</bool>
<item row="1" column="1">
<widget class="QLineEdit" name="valSaneName">
<property name="toolTip">
- <string notr="true">file adress (ex: /home/A123456/cuve.med)</string>
+ <string notr="true">file address (ex: /home/A123456/cuve.med)</string>
</property>
<property name="autoFillBackground">
<bool>true</bool>
self.txtSaneName.setObjectName(_fromUtf8("txtSaneName"))
self.gridLayout.addWidget(self.txtSaneName, 1, 0, 1, 1)
self.valSaneName = QtGui.QLineEdit(self.gridLayoutWidget)
- self.valSaneName.setToolTip(_fromUtf8("file adress (ex: /home/A123456/cuve.med)"))
+ self.valSaneName.setToolTip(_fromUtf8("file address (ex: /home/A123456/cuve.med)"))
self.valSaneName.setAutoFillBackground(True)
self.valSaneName.setInputMask(_fromUtf8(""))
self.valSaneName.setText(_fromUtf8(""))
def retranslateUi(self, Zui):
Zui.setWindowTitle(_translate("Zui", "Zcracks interface - version dev", None))
- self.btReset.setToolTip(_translate("Zui", "Clear all paramters", None))
+ self.btReset.setToolTip(_translate("Zui", "Clear all parameters", None))
self.btReset.setText(_translate("Zui", "Reset", None))
self.btSave.setToolTip(_translate("Zui", "Save parameters in a file", None))
self.btSave.setText(_translate("Zui", "Save", None))
self.btApplyClose.setText(_translate("Zui", "Apply and close", None))
self.txtCrackedName.setToolTip(_translate("Zui", "Name of the resulting cracked mesh", None))
self.txtCrackedName.setText(_translate("Zui", "Cracked name", None))
- self.valCrackedName.setToolTip(_translate("Zui", "file adress (ex: /home/A123456/cracked.med)", None))
+ self.valCrackedName.setToolTip(_translate("Zui", "file address (ex: /home/A123456/cracked.med)", None))
self.txtSaneName.setToolTip(_translate("Zui", "Name of the sane mesh", None))
self.txtSaneName.setText(_translate("Zui", "Sane mesh", None))
self.btLoadCracked.setText(_translate("Zui", "...", None))
defaultres = local
# The following sections defines the available configurations.
-# The name of the section can be choosen arbitrary. But the value of
+# The name of the section can be chosen arbitrarily. But the value of
# the resname key MUST be the name of a SALOME resource defined in the
# catalog of resources (CatalogResources.xml).
}
/*!
- * This function creates a shell script that runs padder whith the
+ * This function creates a shell script that runs padder with the
* specified data file, and returns the path of the created script
* file. The config id is used to retrieve the path to the binary file
* and other required files.
}
}
- // Then, we have to specify the existance of an output filename. The
+ // Then, we have to specify the existence of an output filename. The
// path is supposed to be a path on the remote resource, i.e. where
// the job is executed.
jobParameters->out_files.length(1);
// account not only the data that could be loaded by the batch
// process but also the linked dynamic library.
//
- // A possible problem, for exemple in the case where you use the ssh
+ // A possible problem, for example in the case where you use the ssh
// emulation of a batch system, is to get an error message as below
// when libBatch try to run the ssh command:
//
// ## /usr/bin/ssh: error while loading shared libraries: libcrypto.so.0.9.8: failed
// ## to map segment from shared object: Cannot allocate memory
//
- // In this exemple, the mem_mb was set to 1MB, value that is not
+ // In this example, the mem_mb was set to 1MB, value that is not
// sufficient to load the dynamic libraries linked to the ssh
// executable (libcrypto.so in the error message).
//
# items in the object browser:
self.__inputDialog.setWindowFlags(
self.__inputDialog.windowFlags() | Qt.WindowStaysOnTopHint)
- # The signal inputValidated emited from inputDialog is
+ # The signal inputValidated emitted from inputDialog is
# connected to the slot function onProcessInput:
self.__inputDialog.inputValidated.connect( self.onProcessInput )
defaultres = local
# The following sections defines the available configurations.
-# The name of the section can be choosen arbitrary. But the value of
+# The name of the section can be chosen arbitrarily. But the value of
# the resname key MUST be the name of a SALOME resource defined in the
# catalog of resources (CatalogResources.xml).