Houdini Engine 7.0
|
Functions | |
HAPI_DECL | HAPI_GetStatus (const HAPI_Session *session, HAPI_StatusType status_type, int *status) |
Gives back the status code for a specific status type. More... | |
HAPI_DECL | HAPI_GetStatusStringBufLength (const HAPI_Session *session, HAPI_StatusType status_type, HAPI_StatusVerbosity verbosity, int *buffer_length) |
Return length of string buffer storing status string message. More... | |
HAPI_DECL | HAPI_GetStatusString (const HAPI_Session *session, HAPI_StatusType status_type, char *string_value, int length) |
Return status string message. More... | |
HAPI_DECL | HAPI_ComposeNodeCookResult (const HAPI_Session *session, HAPI_NodeId node_id, HAPI_StatusVerbosity verbosity, int *buffer_length) |
Compose the cook result string (errors and warnings) of a specific node. More... | |
HAPI_DECL | HAPI_GetComposedNodeCookResult (const HAPI_Session *session, char *string_value, int length) |
Return cook result string message on a single node. More... | |
HAPI_DECL | HAPI_GetNodeCookResultLength (const HAPI_Session *session, HAPI_NodeId node_id, HAPI_StatusVerbosity verbosity, int *buffer_length) |
Gets the length of the cook result string (errors and warnings) of a specific node. More... | |
HAPI_DECL | HAPI_GetNodeCookResult (const HAPI_Session *session, char *string_value, int length) |
Return the cook result string that was composed during a call to HAPI_GetNodeCookResultLength(). More... | |
HAPI_DECL | HAPI_GetMessageNodeCount (const HAPI_Session *session, HAPI_NodeId node_id, int *count) |
Get the number of message nodes set in "Type Properties". More... | |
HAPI_DECL | HAPI_GetMessageNodeIds (const HAPI_Session *session, HAPI_NodeId node_id, HAPI_NodeId *message_node_ids_array, int count) |
Get the ids of message nodes set in the "Type Properties". More... | |
HAPI_DECL | HAPI_CheckForSpecificErrors (const HAPI_Session *session, HAPI_NodeId node_id, HAPI_ErrorCodeBits errors_to_look_for, HAPI_ErrorCodeBits *errors_found) |
Recursively check for specific errors by error code on a node. More... | |
HAPI_DECL | HAPI_ClearConnectionError () |
Clears the connection error. Should be used before starting or creating Thrift server. More... | |
HAPI_DECL | HAPI_GetConnectionErrorLength (int *buffer_length) |
Return the length of string buffer storing connection error message. More... | |
HAPI_DECL | HAPI_GetConnectionError (char *string_value, int length, HAPI_Bool clear) |
Return the connection error message. More... | |
HAPI_DECL | HAPI_GetCookingTotalCount (const HAPI_Session *session, int *count) |
Get total number of nodes that need to cook in the current session. More... | |
HAPI_DECL | HAPI_GetCookingCurrentCount (const HAPI_Session *session, int *count) |
Get current number of nodes that have already cooked in the current session. Note that this is a very crude approximation of the cooking progress - it may never make it to 100% or it might spend another hour at 100%. Use HAPI_GetStatusString to get a better idea of progress if this number gets stuck. More... | |
HAPI_DECL | HAPI_Interrupt (const HAPI_Session *session) |
Interrupt a cook or load operation. More... | |
HAPI_DECL | HAPI_GetJobStatus (const HAPI_Session *session, int job_id, HAPI_JobStatus *job_status) |
Get status of a job. More... | |
Functions for reading session connection and cook status.
HAPI_DECL HAPI_CheckForSpecificErrors | ( | const HAPI_Session * | session, |
HAPI_NodeId | node_id, | ||
HAPI_ErrorCodeBits | errors_to_look_for, | ||
HAPI_ErrorCodeBits * | errors_found | ||
) |
Recursively check for specific errors by error code on a node.
Note that checking for errors can be expensive because it checks ALL child nodes within a node and then tries to do a string match for the errors being looked for. This is why such error checking is part of a standalone function and not done during the cooking step.
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | node_id | The node id. |
[in] | errors_to_look_for | The HAPI_ErrorCode error codes (as a bitfield) to look for. |
[out] | errors_found | Returned HAPI_ErrorCode bitfield indicating which of the looked for errors have been found. |
HAPI_DECL HAPI_ClearConnectionError | ( | ) |
Clears the connection error. Should be used before starting or creating Thrift server.
Only available when using Thrift connections.
HAPI_DECL HAPI_ComposeNodeCookResult | ( | const HAPI_Session * | session, |
HAPI_NodeId | node_id, | ||
HAPI_StatusVerbosity | verbosity, | ||
int * | buffer_length | ||
) |
Compose the cook result string (errors and warnings) of a specific node.
This will actually parse the node network inside the given node and return ALL errors/warnings/messages of all child nodes, combined into a single string. If you'd like a more narrowed search, call this function on one of the child nodes.
You MUST call HAPI_ComposeNodeCookResult() before calling HAPI_GetComposedNodeCookResult() because HAPI_GetComposedNodeCookResult() will not return the real result string and instead return a cached version of the string that was created inside HAPI_ComposeNodeCookResult(). The reason for this is that the length of the real status string may change between the call to HAPI_ComposeNodeCookResult() and the call to HAPI_GetComposedNodeCookResult().
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | node_id | The node id. |
[in] | verbosity | Preferred verbosity level. |
[out] | buffer_length | Length of buffer char array ready to be filled. |
HAPI_DECL HAPI_GetComposedNodeCookResult | ( | const HAPI_Session * | session, |
char * | string_value, | ||
int | length | ||
) |
Return cook result string message on a single node.
You MUST call HAPI_ComposeNodeCookResult() before calling HAPI_GetComposedNodeCookResult() because HAPI_GetComposedNodeCookResult() will not return the real result string and instead return a cached version of the string that was created inside HAPI_ComposeNodeCookResult(). The reason for this is that the length of the real status string may change between the call to HAPI_ComposeNodeCookResult() and the call to HAPI_GetComposedNodeCookResult().
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[out] | string_value | Buffer char array ready to be filled. |
[in] | length | Length of the string buffer (must match size of string_value - so including NULL terminator). |
Return the connection error message.
You MUST call HAPI_GetConnectionErrorLength() before calling this to get the correct string length.
Only available when using Thrift connections.
[out] | string_value | Buffer char array ready to be filled. |
[in] | length | Length of the string buffer (must match size of string_value - so including NULL terminator). Use HAPI_GetConnectionErrorLength to get this length. |
[in] | clear | If true, will clear the error when HAPI_RESULT_SUCCESS is returned. |
HAPI_DECL HAPI_GetConnectionErrorLength | ( | int * | buffer_length | ) |
Return the length of string buffer storing connection error message.
Only available when using Thrift connections.
[out] | buffer_length | Length of buffer char array ready to be filled. |
HAPI_DECL HAPI_GetCookingCurrentCount | ( | const HAPI_Session * | session, |
int * | count | ||
) |
Get current number of nodes that have already cooked in the current session. Note that this is a very crude approximation of the cooking progress - it may never make it to 100% or it might spend another hour at 100%. Use HAPI_GetStatusString to get a better idea of progress if this number gets stuck.
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[out] | count | Current cook count. |
HAPI_DECL HAPI_GetCookingTotalCount | ( | const HAPI_Session * | session, |
int * | count | ||
) |
Get total number of nodes that need to cook in the current session.
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[out] | count | Total cook count. |
HAPI_DECL HAPI_GetJobStatus | ( | const HAPI_Session * | session, |
int | job_id, | ||
HAPI_JobStatus * | job_status | ||
) |
Get status of a job.
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | job_id | The id assigned to the job. It must equal to the index assigned through a previous call to an asynchronous HAPI method. |
[out] | job_status | The current status of the job. One of HAPI_JobStatus. |
HAPI_DECL HAPI_GetMessageNodeCount | ( | const HAPI_Session * | session, |
HAPI_NodeId | node_id, | ||
int * | count | ||
) |
Get the number of message nodes set in "Type Properties".
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | node_id | The node id. |
[out] | count | The number of message nodes. |
HAPI_DECL HAPI_GetMessageNodeIds | ( | const HAPI_Session * | session, |
HAPI_NodeId | node_id, | ||
HAPI_NodeId * | message_node_ids_array, | ||
int | count | ||
) |
Get the ids of message nodes set in the "Type Properties".
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | node_id | The node id. |
[out] | message_node_ids_array | The array of node IDs to be filled. |
[in] | count | The number of message nodes. |
HAPI_DECL HAPI_GetNodeCookResult | ( | const HAPI_Session * | session, |
char * | string_value, | ||
int | length | ||
) |
Return the cook result string that was composed during a call to HAPI_GetNodeCookResultLength().
You MUST call HAPI_GetNodeCookResultLength() before calling HAPI_GetNodeCookResult() because HAPI_GetNodeCookResult() will not return the real result and instead returns a cached version of the string that was created during the call to HAPI_GetNodeCookResultLength(). The reason for this is that the length of the real status string may change between the call to HAPI_GetNodeCookResultLength() and HAPI_GetNodeCookResult().
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[out] | string_value | Buffer char array that will be filled with the cook result string. |
[in] | length | Length of the char buffer (must match size of string_value - so include NULL terminator). |
HAPI_DECL HAPI_GetNodeCookResultLength | ( | const HAPI_Session * | session, |
HAPI_NodeId | node_id, | ||
HAPI_StatusVerbosity | verbosity, | ||
int * | buffer_length | ||
) |
Gets the length of the cook result string (errors and warnings) of a specific node.
Unlike HAPI_ComposeNodeCookResult(), this node does not parse inside the node network. Only errors, warnings, and messages that appear on the specified node will be a part of the cook result string.
You MUST call HAPI_GetNodeCookResultLength() before calling HAPI_GetNodeCookResult() because HAPI_GetNodeCookResult() will not return the real result and instead returns a cached version of the string that was created during the call to HAPI_GetNodeCookResultLength(). The reason for this is that the length of the real status string may change between the call to HAPI_GetNodeCookResultLength() and HAPI_GetNodeCookResult().
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | node_id | The node id. |
[in] | verbosity | Preferred verbosity level. |
[out] | buffer_length | Lenght of buffer char array ready to be filled. |
HAPI_DECL HAPI_GetStatus | ( | const HAPI_Session * | session, |
HAPI_StatusType | status_type, | ||
int * | status | ||
) |
Gives back the status code for a specific status type.
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | status_type | One of HAPI_StatusType. |
[out] | status | Actual status code for the status type given. That is, if you pass in HAPI_STATUS_CALL_RESULT as status_type, you'll get back a HAPI_Result for this argument. If you pass in HAPI_STATUS_COOK_STATE as status_type, you'll get back a HAPI_State enum for this argument. |
HAPI_DECL HAPI_GetStatusString | ( | const HAPI_Session * | session, |
HAPI_StatusType | status_type, | ||
char * | string_value, | ||
int | length | ||
) |
Return status string message.
You MUST call HAPI_GetStatusStringBufLength() before calling HAPI_GetStatusString() because HAPI_GetStatusString() will not return the real status string and instead return a cached version of the string that was created inside HAPI_GetStatusStringBufLength(). The reason for this is that the length of the real status string may change between the call to HAPI_GetStatusStringBufLength() and the call to HAPI_GetStatusString().
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | status_type | One of HAPI_StatusType. |
[out] | string_value | Buffer char array ready to be filled. |
[in] | length | Length of the string buffer (must match size of string_value - so including NULL terminator). |
HAPI_DECL HAPI_GetStatusStringBufLength | ( | const HAPI_Session * | session, |
HAPI_StatusType | status_type, | ||
HAPI_StatusVerbosity | verbosity, | ||
int * | buffer_length | ||
) |
Return length of string buffer storing status string message.
If called with HAPI_STATUS_COOK_RESULT this will actually parse the node networks for the previously cooked asset(s) and aggregate all node errors, warnings, and messages (depending on the verbosity
level set). Usually this is done just for the last cooked single asset but if you load a whole Houdini scene using HAPI_LoadHIPFile() then you'll have multiple "previously cooked assets".
You MUST call HAPI_GetStatusStringBufLength() before calling HAPI_GetStatusString() because HAPI_GetStatusString() will not return the real status string and instead return a cached version of the string that was created inside HAPI_GetStatusStringBufLength(). The reason for this is that the length of the real status string may change between the call to HAPI_GetStatusStringBufLength() and the call to HAPI_GetStatusString().
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |
[in] | status_type | One of HAPI_StatusType. |
[in] | verbosity | Preferred verbosity level. |
[out] | buffer_length | Length of buffer char array ready to be filled. |
HAPI_DECL HAPI_Interrupt | ( | const HAPI_Session * | session | ) |
Interrupt a cook or load operation.
[in] | session | The session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session. |