camitk.MeshComponent¶
- class camitk.MeshComponent¶
Basic component to manage any kind of mesh.
- __init__(*args, **kwargs)¶
Methods
__init__(*args, **kwargs)addCellData(self, arg0, arg1)Adds a cell data array using the given numpy ndarray.
addChild(self, arg0)add a child Component (sub item in the hierarchy), and modify the child's parent to be equal to this instance
addDataArray(self, arg0, arg1, arg2)Add a data array using the given a numpy ndarray.
addPointData(self, arg0, arg1)Adds a point data array using the given numpy ndarray.
clone(self)Clone this original mesh.
getChildren(self)get the list of the InterfaceNode children (sub items in the hierarchy)
getColor(self)Get the color of given representation modes in the second parameter.
getDataArray(self, arg0, arg1)Get the data array of specified field type and index as a numpy ndarray.
getFileName(self)get the file name where the data have to be stored/were stored
getFrame(self)Get the pointer to this object's FrameOfReference.
getName(self)get the name to be displayed
getNumberOfDataArray(self, arg0)Get the number of data arrays of a given type without taking the specific representation into account.
getParent(self)get the parent Component
getPickedCellId(self)get the last pick point id,
getPickedPointId(self)get the last pick point id,
getPickedPointPosition(self)Returns the position of the picked point as a tuple of 3 floats (x, y, z) in this mesh component frame.
getPointSetAsNumpy(self)Returns the point set as a numpy ndarray of shape (N, 3) where N is the number of points.
getPropertyValue(self, arg0)get the property QVariant (same as property(const char*)) but check if it exists first.
isSelected(self)Check if this data component is selected
isTopLevel(self)return true if this component is a top-level component
refresh(self)refresh all the viewer that are currently displaying this Component At the end the InterfaceNode modification flag is reset.
removeDataArray(self, arg0, arg1)Remove a data array.
replacePointSet(self, arg0)Replaces the point set with the given numpy ndarray of shape (N, 3) where N is the number of points.
setColor(self, arg0)Set the color of given representation modes.
setDataRepresentationOff(self[, dataType, ...])hide all the data representation of a given data type (hide all by default) By default this->refresh() is called unless blockRefresh is set to true
setFrame(self, arg0)Set the FrameOfReference of this object.
setFrameFrom(self, arg0)Modify this object's frame using the given object's frame.
setLinesAsTubes(self[, isTubes, ...])Set the lines as tubes (works only for vtkDataSet representation that contains lines)
setModified(self, arg0)set the modified flag
setName(self, arg0)set the name to be displayed
setPropertyValue(self, arg0, arg1)set the property QVariant value (same as setProperty(const char*, newValue)) but check if it exists first.
setRenderingModes(self, arg0)@name rendering mode settings @{ Set the actor associated to a rendering mode visible or not.
setSelected(self, b[, recursive])Update the selection flag.
Attributes
CELLSMESHNoRenderingModePOINTSPointsSurfaceWireframe