Topological item owners
Data Structures | |
struct | A3DTopoItemOwner |
Structure is a linked list for storing topology items owners. More... | |
Typedefs | |
typedef void | A3DTopoItemOwnersManager |
Functions | |
A3DStatus | A3DTopoItemOwnersGet (A3DTopoItemOwnersManager *pTopoItemOwnersManager, const A3DTopoItem *pTopoItem, A3DTopoItemOwner **ppTopoItemOwner) |
Gets owners of topology item. More... | |
A3DStatus | A3DTopoItemOwnersManagerGet (const A3DRiRepresentationItem *pBrepOwner, A3DTopoItemOwnersManager **ppTopoItemOwnersManager) |
Structure for storing topology items owners. More... | |
Detailed Description
- Version
- 5.0
Typedef Documentation
◆ A3DTopoItemOwnersManager
typedef void A3DTopoItemOwnersManager |
Database used to store links between topology items and their owners.
Function Documentation
◆ A3DTopoItemOwnersManagerGet()
A3DStatus A3DTopoItemOwnersManagerGet | ( | const A3DRiRepresentationItem * | pBrepOwner, |
A3DTopoItemOwnersManager ** | ppTopoItemOwnersManager | ||
) |
Structure for storing topology items owners.
- Version
- 5.0 Methods and structures dedicated to managing the link between topology items and their owner(s).
Creates manager of topology items fron an A3DRiRepresentationItem
- Version
- 5.0
- This function creates a map, on request, between topological items and linked lists of owners. When the map is built, the function A3DTopoItemOwnersGet lets you retrieve owners of specific topological item. For example, if you need the faces owner of edges, first you build your map, then you retrieve the owner list for each edge. The following code shows how to use it.
// map creation
A3DTopoItemOwnersManager* pTopologyOwnersManager = NULL;
return A3D_ERROR;
if(pTopologyOwnersManager == NULL)
return A3D_ERROR;
// edge owners = CoEdge
A3DTopoItemOwner* pOwningCoEdge = NULL;
A3DTopoItemOwnersGet(pTopologyOwnersManager, pEdge, pOwningCoEdge);
while( pOwningCoEdge!=NULL)
{
// coedge owners = Loop
A3DTopoItemOwner* pOwningLoop = NULL;
A3DTopoItemOwnersGet(pTopologyOwnersManager, pOwningCoEdge->m_pTopoItem, pOwningLoop);
while( pOwningLoop!=NULL)
{
// Loop owners = face
A3DTopoItemOwner* pOwingFace = NULL;
A3DTopoItemOwnersGet(pTopologyOwnersManager, pOwningLoop->m_pTopoItem, pOwingFace);
while( pOwingFace!=NULL)
{
return A3D_ERROR;
if(entityType != kA3DTypeTopoFace)
return A3D_ERROR;
pOwingFace = pOwingFace->m_pNext;
}
pOwningLoop = pOwningLoop->m_pNext;
}
pOwningCoEdge = pOwningCoEdge->m_pNext;
}
Note that, if A3DTopoItemOwnersManagerGet is called several times with the same representation item, the map is not recomputed; and if the representation item is null, the map is released.
- Returns
- A3D_SUCCESS in case of success or an error code
- Return values
-
A3D_SUCCESS A3D_INVALID_ENTITY_TYPE A3D_ERROR
◆ A3DTopoItemOwnersGet()
A3DStatus A3DTopoItemOwnersGet | ( | A3DTopoItemOwnersManager * | pTopoItemOwnersManager, |
const A3DTopoItem * | pTopoItem, | ||
A3DTopoItemOwner ** | ppTopoItemOwner | ||
) |
Gets owners of topology item.
- Version
- 5.0
- Returns
- A3D_SUCCESS in case of success or an error code
- Return values
-
A3D_SUCCESS A3D_INVALID_ENTITY_TYPE A3D_ERROR