Back to index

salome-smesh  6.5.0
Functions
Mesh through point
Modifying meshes
Collaboration diagram for Mesh through point:

Functions

def smeshDC.Mesh.MoveClosestNodeToPoint
 Finds the node closest to a point and moves it to a point location.
def smeshDC.Mesh.FindNodeClosestTo
 Finds the node closest to a point.
def smeshDC.Mesh.FindElementsByPoint
 Finds the elements where a point lays IN or ON.
def smeshDC.Mesh.MeshToPassThroughAPoint
 Finds the node closest to a point and moves it to a point location.

Function Documentation

def smeshDC.Mesh.FindElementsByPoint (   self,
  x,
  y,
  z,
  elementType = SMESH.ALL,
  meshPart = None 
)

Finds the elements where a point lays IN or ON.

Parameters:
xthe X coordinate of a point
ythe Y coordinate of a point
zthe Z coordinate of a point
elementTypetype of elements to find (SMESH.ALL type means elements of any type excluding nodes and 0D elements)
meshParta part of mesh (group, sub-mesh) to search within
Returns:
list of IDs of found elements

Definition at line 2488 of file smeshDC.py.

02488 
02489     def FindElementsByPoint(self, x, y, z, elementType = SMESH.ALL, meshPart=None):
02490         if meshPart:
02491             return self.editor.FindAmongElementsByPoint( meshPart, x, y, z, elementType );
02492         else:
02493             return self.editor.FindElementsByPoint(x, y, z, elementType)

def smeshDC.Mesh.FindNodeClosestTo (   self,
  x,
  y,
  z 
)

Finds the node closest to a point.

Parameters:
xthe X coordinate of a point
ythe Y coordinate of a point
zthe Z coordinate of a point
Returns:
the ID of a node

Definition at line 2474 of file smeshDC.py.

02474 
02475     def FindNodeClosestTo(self, x, y, z):
02476         #preview = self.mesh.GetMeshEditPreviewer()
02477         #return preview.MoveClosestNodeToPoint(x, y, z, -1)
02478         return self.editor.FindNodeClosestTo(x, y, z)

def smeshDC.Mesh.MeshToPassThroughAPoint (   self,
  x,
  y,
  z 
)

Finds the node closest to a point and moves it to a point location.

Parameters:
xthe X coordinate of a point
ythe Y coordinate of a point
zthe Z coordinate of a point
Returns:
the ID of a moved node

Definition at line 2506 of file smeshDC.py.

02506 
02507     def MeshToPassThroughAPoint(self, x, y, z):
02508         return self.editor.MoveClosestNodeToPoint(x, y, z, -1)

def smeshDC.Mesh.MoveClosestNodeToPoint (   self,
  x,
  y,
  z,
  NodeID 
)

Finds the node closest to a point and moves it to a point location.

Parameters:
xthe X coordinate of a point
ythe Y coordinate of a point
zthe Z coordinate of a point
NodeIDif specified (>0), the node with this ID is moved, otherwise, the node closest to point (x,y,z) is moved
Returns:
the ID of a node

Definition at line 2463 of file smeshDC.py.

02463 
02464     def MoveClosestNodeToPoint(self, x, y, z, NodeID):
02465         x,y,z,Parameters,hasVars = ParseParameters(x,y,z)
02466         if hasVars: self.mesh.SetParameters(Parameters)
02467         return self.editor.MoveClosestNodeToPoint(x, y, z, NodeID)

Here is the call graph for this function: