int sm_replay_status(struct sm_replay_status_parms *statusp)
typedef struct sm_replay_status_parms { tSMChannelId channel; /* inout */ enum kSMReplayStatus { kSMReplayStatusComplete, kSMReplayStatusCompleteData, kSMReplayStatusUnderrun, kSMReplayStatusHasCapacity, kSMReplayStatusNoCapacity, } status; /* out */ tSM_UT32 offset; /* out */ } SM_REPLAY_STATUS_PARMS;
This call, typically invoked in response to a write event being signalled, allows an application to determine the status of replay jobs.
In order to determine the status of a specific replay job on a particular output channel, the application should set channel to specify the job concerned. On successful completion, the status field indicates the current status of the channel.
This function can also be used for 'any channel' operation. This mode of operation is a legacy feature and is not recommended for new applications. See Prosody TiNG: any channel operation for more details.
A channel ceases to be replaying when this function returns a
status of
kSMReplayStatusComplete.
Until this happens, the channel output is reserved for the
replay and cannot be used for anything else. After this
happens, the channel output returns to being idle and
consequently if this function is used again it will return
the error ERR_SM_NO_REPLAY_IN_PROGRESS
.
0 if call completed successfully, otherwise a standard error such as:
This function is part of the Prosody speech processing API.