13#define SG_COM_PLAYER_VERSION_NAME "5.3.0"
172 double *current_time_ms
void(* SG_LoggingCallback)(const char *message)
Callback that will be called by an Engine to output log messages.
#define SG_DYN
Used to determine if we are building a shared library, as opposed to building a static library or con...
SG_LoggingLevel
Enum for logging level.
struct SG_COM_PLAYER_Config SG_COM_PLAYER_Config
Structure containing a Player configuration.
SG_DYN const char * SG_COM_PLAYER_GetVersionString(void)
Get the runtime version number for this library in string format.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_Initialize(SG_LoggingLevel logging_level, SG_LoggingCallback logging_callback)
Initialize the internal context of SG Com.
SG_DYN const char * SG_COM_PLAYER_GetExceptionText(void)
Retrieve exception text after SG_COM_PLAYER_ERROR_EXCEPTION error.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_Shutdown(void)
Shut down and dispose of the internal context of SG Com.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_Create(const SG_COM_PLAYER_Config *player_config, SG_COM_PLAYER_Handle *player_handle)
Create a Player to play the output from a Broadcast Engine.
struct SG_COM_PLAYER_Context * SG_COM_PLAYER_Handle
Handle type.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_GetPlayableRange(SG_COM_PLAYER_Handle player_handle, double *min_time_ms, double *max_time_ms)
Get the range of buffered animation.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_Destroy(SG_COM_PLAYER_Handle player_handle)
Destroy a Player.
SG_COM_PLAYER_Error
Enum of error codes.
@ SG_COM_PLAYER_ERROR_INVALID_PACKET
An invalid data packet was received.
@ SG_COM_PLAYER_ERROR_INVALID_EVENT
An invalid event was received.
@ SG_COM_PLAYER_ERROR_OK
No error.
@ SG_COM_PLAYER_ERROR_INVALID_PARAM
An invalid parameter was passed to a function.
@ SG_COM_PLAYER_ERROR_OUT_OF_ORDER_PACKET_DISCARDED
A data packet was received out of order and was discarded.
@ SG_COM_PLAYER_ERROR_EXCEPTION
An exception was raised, call SG_COM_PLAYER_GetExceptionText() for details.
@ SG_COM_PLAYER_ERROR_UNDEFINED
An unclassified error occurred.
@ SG_COM_PLAYER_ERROR_NOT_IMPLEMENTED
This operation is not implemented.
@ SG_COM_PLAYER_ERROR_INVALID_HANDLE
An invalid Engine or Player was created or referenced.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_ReceivePacket(SG_COM_PLAYER_Handle player_handle, const char *packet, sg_size packet_bytes)
Receive an output packet from an Engine into the corresponding Player.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_GetAnimationNodes(SG_COM_PLAYER_Handle player_handle, SG_AnimationNode **animation_nodes, sg_size *num_animation_nodes)
Get the animation nodes for a given Player.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_ReceiveEvent(SG_COM_PLAYER_Handle player_handle, const char *event, sg_size event_bytes)
Receive an event loaded in memory into the corresponding Player.
SG_DYN SG_COM_PLAYER_Error SG_COM_PLAYER_UpdateAnimation(SG_COM_PLAYER_Handle player_handle, double time_ms, double *current_time_ms)
Set the current play time and update the animation nodes.
SG_DYN unsigned int SG_COM_PLAYER_GetVersionNumber(void)
Get the runtime version number for this library.
Structure containing an animation node.
Structure containing a Player configuration.
sg_byte * character_file_in_memory
The character file data loaded into memory.
float buffer_sec
The maximum duration (in seconds) that the output buffer can hold.
sg_size character_file_bytes
The size of the character file data in bytes.