This function is only in Prosody version 1 (see also the conversion guide for further details).
int sm_switch_channel_ix(struct sm_switch_channel_ix_parms *switchp)
typedef struct sm_switch_channel_ix_parms {
tSM_INT channel_ix; /* in */
tSM_INT st; /* in */
tSM_INT ts; /* in */
tSM_INT switch_output; /* in */
} SM_SWITCH_CHANNEL_IX_PARMS;
An application may use this call as an alternative to sm_switch_channel_input() or sm_switch_channel_output() in the case where the subject channel needs to be referred to by a channel index and not a channel id (for instance when the part of the application handling switching of data to channels is located in a process distinct from that where the channels were allocated and thus the channel ids are not be valid in this process).
Applicable only to channels located on Prosody ISA card speech processing modules.
If switch_output is non-zero and channel_ix is set to the channel index for the channel to be switched, then sm_switch_channel_ix will behave like sm_switch_channel_output().
If switch_output is zero and channel_ix is set to the channel index for the channel to be switched, then sm_switch_channel_ix will behave like sm_switch_channel_input().
0 if call completed successfully, otherwise a standard error such as:
This function is part of the Prosody generic API.