DzIndexList Class Reference
[Basic Objects]

Represents a sorted list of indices - such as a group of vertices, or faces. More...

Inheritance diagram for DzIndexList:

DzBase QObject Object DzSubDGroup DzVertexGroup List of all members.

Methods

void addIndex (Number idx)
void clear ()
Number count ()
int findIndex (Number idx) Boolean removeIndex(Number idx)
Number getIndex (Number i)
Boolean removeComponent (Number idx)

Detailed Description

Represents a sorted list of indices - such as a group of vertices, or faces.


Member Function Documentation

void DzIndexList::addIndex ( Number  idx  ) 

Adds an index to the list.

Parameters:
idx The index to append to the list.

void DzIndexList::clear (  ) 

Removes all indices from the list and sets its count to zero.

Number DzIndexList::count (  ) 

Returns:
The number of indices in the list.

int DzIndexList::findIndex ( Number  idx  ) 

Finds an index in the list.

Parameters:
idx The index to find in the list.
Returns:
The index (in the list) for the requested index. Returns -1 if the index is not found.

Number DzIndexList::getIndex ( Number  idx  ) 

Parameters:
The position of the index to return.
Returns:
The index at the given position in the list.

Boolean DzIndexList::removeComponent ( Number  idx  ) 

This function is typically called when a component (e.g. vertex or face) has been removed from the list that the indices in this list reference. This function removes the given index from the list if it is found, and decrements all indices in the list greater than the given index in order to 'clean-up' the list of indices.

Parameters:
idx The index of the item that needs to be removed.
Returns:
true on sucess, otherwise false.


Generated on Thu Sep 24 12:21:12 2009

Copyright © 2002 - 2009 DAZ 3D, Inc.