mirror of
https://github.com/xiph/opus.git
synced 2025-06-01 16:17:42 +00:00
Makes OPUS_SET_VOICE_RATIO private
Let's put it back in if/when we have a clearer view of voice/music detection
This commit is contained in:
parent
6ef378725f
commit
e6a0be8ee6
3 changed files with 22 additions and 18 deletions
|
@ -95,8 +95,6 @@ extern "C" {
|
|||
#define OPUS_GET_PACKET_LOSS_PERC_REQUEST 4015
|
||||
#define OPUS_SET_DTX_REQUEST 4016
|
||||
#define OPUS_GET_DTX_REQUEST 4017
|
||||
#define OPUS_SET_VOICE_RATIO_REQUEST 4018
|
||||
#define OPUS_GET_VOICE_RATIO_REQUEST 4019
|
||||
#define OPUS_SET_VBR_CONSTRAINT_REQUEST 4020
|
||||
#define OPUS_GET_VBR_CONSTRAINT_REQUEST 4021
|
||||
#define OPUS_SET_FORCE_CHANNELS_REQUEST 4022
|
||||
|
@ -259,21 +257,6 @@ extern "C" {
|
|||
* @hideinitializer */
|
||||
#define OPUS_GET_SIGNAL(x) OPUS_GET_SIGNAL_REQUEST, __opus_check_int_ptr(x)
|
||||
|
||||
/** Configures the encoder's expected percentage of voice
|
||||
* opposed to music or other signals.
|
||||
*
|
||||
* @note This interface is currently more aspiration than actuality. It's
|
||||
* ultimately expected to bias an automatic signal classifier, but it currently
|
||||
* just shifts the static bitrate to mode mapping around a little bit.
|
||||
*
|
||||
* @param[in] x <tt>int</tt>: Voice percentage in the range 0-100, inclusive.
|
||||
* @hideinitializer */
|
||||
#define OPUS_SET_VOICE_RATIO(x) OPUS_SET_VOICE_RATIO_REQUEST, __opus_check_int(x)
|
||||
/** Gets the encoder's configured voice ratio value, @see OPUS_SET_VOICE_RATIO
|
||||
*
|
||||
* @param[out] x <tt>int*</tt>: Voice percentage in the range 0-100, inclusive.
|
||||
* @hideinitializer */
|
||||
#define OPUS_GET_VOICE_RATIO(x) OPUS_GET_VOICE_RATIO_REQUEST, __opus_check_int_ptr(x)
|
||||
|
||||
/** Configures the encoder's intended application.
|
||||
* The initial value is a mandatory argument to the encoder_create function.
|
||||
|
|
|
@ -36,6 +36,26 @@
|
|||
#define MODE_HYBRID 1001
|
||||
#define MODE_CELT_ONLY 1002
|
||||
|
||||
#define OPUS_SET_VOICE_RATIO_REQUEST 11018
|
||||
#define OPUS_GET_VOICE_RATIO_REQUEST 11019
|
||||
|
||||
/** Configures the encoder's expected percentage of voice
|
||||
* opposed to music or other signals.
|
||||
*
|
||||
* @note This interface is currently more aspiration than actuality. It's
|
||||
* ultimately expected to bias an automatic signal classifier, but it currently
|
||||
* just shifts the static bitrate to mode mapping around a little bit.
|
||||
*
|
||||
* @param[in] x <tt>int</tt>: Voice percentage in the range 0-100, inclusive.
|
||||
* @hideinitializer */
|
||||
#define OPUS_SET_VOICE_RATIO(x) OPUS_SET_VOICE_RATIO_REQUEST, __opus_check_int(x)
|
||||
/** Gets the encoder's configured voice ratio value, @see OPUS_SET_VOICE_RATIO
|
||||
*
|
||||
* @param[out] x <tt>int*</tt>: Voice percentage in the range 0-100, inclusive.
|
||||
* @hideinitializer */
|
||||
#define OPUS_GET_VOICE_RATIO(x) OPUS_GET_VOICE_RATIO_REQUEST, __opus_check_int_ptr(x)
|
||||
|
||||
|
||||
#define OPUS_SET_FORCE_MODE_REQUEST 11002
|
||||
#define OPUS_SET_FORCE_MODE(x) OPUS_SET_FORCE_MODE_REQUEST, __opus_check_int(x)
|
||||
|
||||
|
|
|
@ -871,10 +871,11 @@ opus_int32 test_enc_api(void)
|
|||
" OPUS_SET_VBR ................................ OK.\n",
|
||||
" OPUS_GET_VBR ................................ OK.\n")
|
||||
|
||||
CHECK_SETGET(OPUS_SET_VOICE_RATIO(i),OPUS_GET_VOICE_RATIO(&i),-2,101,
|
||||
/*CHECK_SETGET(OPUS_SET_VOICE_RATIO(i),OPUS_GET_VOICE_RATIO(&i),-2,101,
|
||||
0,50,
|
||||
" OPUS_SET_VOICE_RATIO ........................ OK.\n",
|
||||
" OPUS_GET_VOICE_RATIO ........................ OK.\n")
|
||||
*/
|
||||
|
||||
CHECK_SETGET(OPUS_SET_VBR_CONSTRAINT(i),OPUS_GET_VBR_CONSTRAINT(&i),-1,2,
|
||||
1,0,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue