API Reference > Functions > getDrawableShapeRepresentation Function
getDrawableShapeRepresentation Function
Syntax
C++
IFCCORE_EXPORT OdResult getDrawableShapeRepresentation(OdGiDrawablePtr pEnt, const OdDAIObjectId& subContextId, OdDAI::Model * pModel, OdDAIObjectId& shapeId, int shapeType);

IfcCore.h

Parameters 
Description 
OdGiDrawablePtr pEnt 
[in] A smart pointer to an entity, that should be converted into a shape representation.  
const OdDAIObjectId& subContextId 
[in] An identifier of the sub-context object to which the shape representation should be added.  
OdDAI::Model * pModel 
[in] A smart pointer to an OdIfcModel object that represents the current model of the file.  
OdDAIObjectId& shapeId 
[out] The object identifier of the created shape representation.  

eOk if the shape representation was successfully created; otherwise, the function returns an appropriate error code.

Creates a shape representation of a specified GiDrawable entity inside a specified model and associates it with a specified representation context.

The method sets the value of the created shape representation's identifier and returns it to a calling subroutine.

Copyright (c) 2002-2021. Open Design Alliance. All rights reserved.