Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.xiph.org/xiph/opus.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Marc Valin <jmvalin@jmvalin.ca>2016-11-04 18:41:13 +0300
committerJean-Marc Valin <jmvalin@jmvalin.ca>2016-11-05 04:25:20 +0300
commit132ed59464dccaae8f1e2f13f168763e99f85d17 (patch)
treedb8aa79783775cf65f3603a4ab3141d99166bed7 /src/opus_multistream_encoder.c
parente619ea76bfaec2b17d09d9c4283c0343d2c10e3f (diff)
Removes OPUS_FRAMESIZE_VARIABLE
That experiment never actually worked
Diffstat (limited to 'src/opus_multistream_encoder.c')
-rw-r--r--src/opus_multistream_encoder.c27
1 files changed, 1 insertions, 26 deletions
diff --git a/src/opus_multistream_encoder.c b/src/opus_multistream_encoder.c
index f0b9ae42..ed93c898 100644
--- a/src/opus_multistream_encoder.c
+++ b/src/opus_multistream_encoder.c
@@ -87,7 +87,6 @@ struct OpusMSEncoder {
int variable_duration;
MappingType mapping_type;
opus_int32 bitrate_bps;
- float subframe_mem[3];
/* Encoder states go here */
/* then opus_val32 window_mem[channels*120]; */
/* then opus_val32 preemph_mem[channels]; */
@@ -461,7 +460,6 @@ static int opus_multistream_encoder_init_impl(
st->layout.nb_channels = channels;
st->layout.nb_streams = streams;
st->layout.nb_coupled_streams = coupled_streams;
- st->subframe_mem[0]=st->subframe_mem[1]=st->subframe_mem[2]=0;
if (mapping_type != MAPPING_TYPE_SURROUND)
st->lfe_stream = -1;
st->bitrate_bps = OPUS_AUTO;
@@ -729,14 +727,6 @@ static void surround_rate_allocation(
+ coupled_ratio*nb_coupled /* stereo */
+ nb_lfe*lfe_ratio;
channel_rate = 256*(opus_int64)(bitrate - lfe_offset*nb_lfe - stream_offset*(nb_coupled+nb_uncoupled) - channel_offset*nb_normal)/total;
-#ifndef FIXED_POINT
- if (st->variable_duration==OPUS_FRAMESIZE_VARIABLE && frame_size != Fs/50)
- {
- opus_int32 bonus;
- bonus = 60*(Fs/frame_size-50);
- channel_rate += bonus;
- }
-#endif
for (i=0;i<st->layout.nb_streams;i++)
{
@@ -788,14 +778,6 @@ static void ambisonics_rate_allocation(
total_rate * rate_ratio_den
/ (rate_ratio_den*num_channels + rate_ratio_num - rate_ratio_den);
-#ifndef FIXED_POINT
- if (st->variable_duration==OPUS_FRAMESIZE_VARIABLE && frame_size != Fs/50)
- {
- opus_int32 bonus = 60*(Fs/frame_size-50);
- non_mono_rate += bonus;
- }
-#endif
-
rate[0] = total_rate - (num_channels - 1) * non_mono_rate;
for (i=1;i<st->layout.nb_streams;i++)
{
@@ -887,13 +869,7 @@ static int opus_multistream_encode_native
opus_encoder_ctl((OpusEncoder*)ptr, OPUS_GET_LOOKAHEAD(&delay_compensation));
delay_compensation -= Fs/400;
- frame_size = compute_frame_size(pcm, analysis_frame_size,
- st->variable_duration, st->layout.nb_channels, Fs, st->bitrate_bps,
- delay_compensation, downmix
-#ifndef DISABLE_FLOAT_API
- , st->subframe_mem
-#endif
- );
+ frame_size = frame_size_select(analysis_frame_size, st->variable_duration, Fs);
}
if (400*frame_size < Fs)
@@ -1346,7 +1322,6 @@ int opus_multistream_encoder_ctl(OpusMSEncoder *st, int request, ...)
case OPUS_RESET_STATE:
{
int s;
- st->subframe_mem[0] = st->subframe_mem[1] = st->subframe_mem[2] = 0;
if (st->mapping_type == MAPPING_TYPE_SURROUND)
{
OPUS_CLEAR(ms_get_preemph_mem(st), st->layout.nb_channels);