C# Class HoudiniEngineUnity.HEU_InputInterfaceMesh

This class provides functionality for uploading Unity mesh data from gameobjects into Houdini through an input node. It derives from the HEU_InputInterface and registers with HEU_InputUtility so that it can be used automatically when uploading mesh data.
Inheritance: HoudiniEngineUnity.HEU_InputInterface
Mostra file Open project: sideeffects/HoudiniEngineForUnity Class Usage Examples

Public Methods

Method Description
CreateInputNodeWithDataUpload ( HoudiniEngineUnity.HEU_SessionBase session, HAPI_NodeId connectNodeID, GameObject inputObject, HAPI_NodeId &inputNodeID ) : bool

Creates a mesh input node and uploads the mesh data from inputObject.

CreateSingleMeshData ( GameObject meshGameObject, bool bExportColliders ) : HEU_InputDataMesh

Returns HEU_UploadMeshData with mesh data found on meshGameObject.

GenerateMeshDatasFromGameObject ( GameObject inputObject, bool bExportColliders = false ) : HEU_InputDataMeshes

Return an input data structure containing mesh data that needs to be uploaded from the given inputObject. Supports child gameobjects with meshes from the given inputObject.

GetUVsFromMesh ( Mesh mesh, Array srcUVs, List destUVs, int index ) : void
Initialize ( HEU_InputInterfaceMeshSettings settings ) : void
IsThisInputObjectSupported ( GameObject inputObject ) : bool
UploadData ( HoudiniEngineUnity.HEU_SessionBase session, HAPI_NodeId inputNodeID, HEU_InputData inputData ) : bool

Upload the inputData (mesh geometry) into the input node with inputNodeID.

Private Methods

Method Description
CreateInputNodeForCollider ( HoudiniEngineUnity.HEU_SessionBase session, HAPI_NodeId &outNodeID, HAPI_NodeId parentNodeId, int colliderIndex, string colliderName, Array colliderVertices, Array colliderIndices ) : bool
GetColliderGroupBaseName ( Collider collider, bool bIsConvex = false, bool bIsSimple = false, bool bIsRendered = false ) : string
GetMeshFromObject ( GameObject meshGameObject ) : Mesh
HEU_InputInterfaceMesh ( ) : System.Collections
OnScriptsReloaded ( ) : void
UploadBoxColliderData ( HoudiniEngineUnity.HEU_SessionBase session, BoxCollider collider, int inputIndex, HAPI_NodeId parentNodeID, HAPI_NodeId &inputNodeID ) : bool
UploadCapsuleColliderData ( HoudiniEngineUnity.HEU_SessionBase session, CapsuleCollider collider, int inputIndex, HAPI_NodeId parentNodeID, HAPI_NodeId &inputNodeID ) : bool
UploadColliderData ( HoudiniEngineUnity.HEU_SessionBase session, HAPI_NodeId mergeNodeID, HEU_InputDataMeshes inputData, HAPI_NodeId parentNodeId ) : bool
UploadMeshColliderData ( HoudiniEngineUnity.HEU_SessionBase session, MeshCollider collider, int inputIndex, HAPI_NodeId parentNodeID, HAPI_NodeId &inputNodeID ) : bool
UploadSphereColliderData ( HoudiniEngineUnity.HEU_SessionBase session, SphereCollider collider, int inputIndex, HAPI_NodeId parentNodeID, HAPI_NodeId &inputNodeID ) : bool

Method Details

CreateInputNodeWithDataUpload() public method

Creates a mesh input node and uploads the mesh data from inputObject.
public CreateInputNodeWithDataUpload ( HoudiniEngineUnity.HEU_SessionBase session, HAPI_NodeId connectNodeID, GameObject inputObject, HAPI_NodeId &inputNodeID ) : bool
session HoudiniEngineUnity.HEU_SessionBase Session that connectNodeID exists in
connectNodeID HAPI_NodeId The node to connect the network to. Most likely a SOP/merge node
inputObject GameObject The gameobject containing the mesh components
inputNodeID HAPI_NodeId The created input node ID
return bool

CreateSingleMeshData() public static method

Returns HEU_UploadMeshData with mesh data found on meshGameObject.
public static CreateSingleMeshData ( GameObject meshGameObject, bool bExportColliders ) : HEU_InputDataMesh
meshGameObject GameObject The GameObject to query mesh data from
bExportColliders bool
return HEU_InputDataMesh

GenerateMeshDatasFromGameObject() public method

Return an input data structure containing mesh data that needs to be uploaded from the given inputObject. Supports child gameobjects with meshes from the given inputObject.
public GenerateMeshDatasFromGameObject ( GameObject inputObject, bool bExportColliders = false ) : HEU_InputDataMeshes
inputObject GameObject GameObject containing mesh components
bExportColliders bool
return HEU_InputDataMeshes

GetUVsFromMesh() public static method

public static GetUVsFromMesh ( Mesh mesh, Array srcUVs, List destUVs, int index ) : void
mesh Mesh
srcUVs Array
destUVs List
index int
return void

Initialize() public method

public Initialize ( HEU_InputInterfaceMeshSettings settings ) : void
settings HEU_InputInterfaceMeshSettings
return void

IsThisInputObjectSupported() public method

public IsThisInputObjectSupported ( GameObject inputObject ) : bool
inputObject GameObject
return bool

UploadData() public method

Upload the inputData (mesh geometry) into the input node with inputNodeID.
public UploadData ( HoudiniEngineUnity.HEU_SessionBase session, HAPI_NodeId inputNodeID, HEU_InputData inputData ) : bool
session HoudiniEngineUnity.HEU_SessionBase Session that the input node exists in
inputNodeID HAPI_NodeId ID of the input node
inputData HEU_InputData Container of the mesh geometry
return bool