int sm_vmptx_config_sample_rate(struct sm_vmptx_sample_rate_parms *sample_ratep)
typedef struct sm_vmptx_sample_rate_parms { tSMVMPtxId vmptx; /* in */ tSM_UT32 sample_rate; /* in */ } SM_VMPTX_SAMPLE_RATE_PARMS;
Allows an application to confgure the sample rate for input to a VMP[tx]. If no rate is configured, it defaults to 8000 samples per second. Some codecs (for example, PCMA - the G.711 A-law codec) can run at any sampling rate, other codecs are designed to run only at specific sampling rates. While the VMP[tx] will attempt to run the codec at the specified rate, running a codec at a non-standard sampling rate may result in unsatisfactory performance.
Note that any data supplied to the VMP[tx] at the wrong sampling rate will be ignored. This allows the sampling rate to be changed without encoding a burst of data at the wrong rate.
0 if call completed successfully, otherwise a standard error such as:
This function is part of the Prosody RTP processing API.