Geometry iterator.
This class is the iterator class for geometry data, and can be used to
loop over the CVs of NURBS, the points of subds & lattices, and the
vertices of polygonal meshes.
Constructor & Destructor Documentation
OpenMaya.MItGeometry.__init__
(
)
Initialize self. See help(type(self)) for accurate signature.
Member Function Documentation
OpenMaya.MItGeometry.__iter__
(
)
Implement iter(self).
OpenMaya.MItGeometry.__new__
(
)
static
Create and return a new object. See help(type) for accurate signature.
OpenMaya.MItGeometry.__next__
(
)
Implement next(self).
OpenMaya.MItGeometry.allPositions
(
)
allPositions() -> MStatus
Return the position of all the points/CVs/vertices. This
operation is faster than using the iterator to get values one by
one, but uses more memory as it requires an array to hold all the
values to be returned.
OpenMaya.MItGeometry.component
(
)
component() -> MObject
DEPRECATED in 2019, use currentItem instead.
This method returns the current component in the iteration.
OpenMaya.MItGeometry.count
(
)
count() -> int
Return the number of items in this iteration. This number will
always be at least as large as the number of items, however in
some cases it may be larger. It is useful if allocating space in
an array to hold the results, since it will always be of
sufficient size. If the exact number of items is required, use the
exactCount method instead. The exactCount method is however
significantly slower than this method.
OpenMaya.MItGeometry.currentItem
(
)
currentItem() -> MObject
This method returns the current component in the iteration.
OpenMaya.MItGeometry.exactCount
(
)
exactCount() -> int
Return the exact number of items in this iteration. This method is
significantly slower than the count() method, so use if only if
the precise number is required.
OpenMaya.MItGeometry.index
(
)
index() -> int
This method returns the index of the current point/CV/vertex
component in the iteration.
OpenMaya.MItGeometry.isDone
(
)
isDone() -> Bool
Indicates end of the iteration.
OpenMaya.MItGeometry.iter
(
)
iter() -> self
Initializes the iterator object for pythonic iteration.
OpenMaya.MItGeometry.iternext
(
)
iternext() -> self
Used in pythonic iteration to move the iterator
OpenMaya.MItGeometry.next
(
)
next() -> self
Advance to the next component in the iteration.
If the iterator is already at the last component then this
method has no effect. Use isDone to determine if the iterator
is at the last component.
OpenMaya.MItGeometry.normal
(
)
normal() -> MVector
Return the normal of the current point/CV/vertex component.
OpenMaya.MItGeometry.position
(
)
position() -> MPoint
Return the position of the current point/CV/vertex component.
OpenMaya.MItGeometry.reset
(
)
reset() -> self
Resets the iterator.
OpenMaya.MItGeometry.setAllPositions
(
)
setAllPositions() -> MStatus
Set the position of all the points/CVs/vertices at once. This
operation is faster than using the iterator to set values one by
one, but uses more memory as it requires an array to hold all the
values to be set.
OpenMaya.MItGeometry.setPosition
(
)
setPosition() -> MStatus
Set the position of the current point/CV/vertex.
OpenMaya.MItGeometry.weight
(
)
weight() -> MWeight
Return the weight of the current point/CV/vertex component.