HM_ExtAPI::MeshGetNextElement()

Returns the next element in a mesh referenced by a mesh object.

Syntax

bool MeshGetNextElement(
const HM_EntityMesh& hmesh,
HM_EntityElement & helem
);

Type

HyperMesh Ext API

Description

The function MeshGetNextElement is used together with the function HM_ExtAPI::MeshGetFirstElement() to iterate through all the elements contained in the mesh referenced by the mesh object. The call to MeshGetFirstElement resets internal element counter of the mesh object to the first element. The following calls to MeshGetNextElement increment the counter until all elements are iterated. If the function succeeds, the return value is true.

If the function fails, the return value is false. To get extended value information, call HM_ExtAPI::GetLastErrorCode().

Requires including hm_extapi.h.

Inputs

hmesh
[in] - Handle to mesh object that was returned by previous calls to API functions.
helem
[out] - Handle to the next element in the mesh referenced by mesh object. The value of the handle is zero in case the mesh does not have elements, or if all elements were already returned by previous calls to MeshGetNextElement function.

Errors

None.