Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Opus
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Xiph.Org
Opus
Commits
66c612ef
Commit
66c612ef
authored
13 years ago
by
Jean-Marc Valin
Browse files
Options
Downloads
Patches
Plain Diff
Fixes an encoder bugg when requesting a CBR rate over the allowable limit
parent
11785e92
No related branches found
Branches containing commit
No related tags found
Tags containing commit
Loading
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
libcelt/mdct.c
+1
-0
1 addition, 0 deletions
libcelt/mdct.c
libcelt/mdct.h
+1
-1
1 addition, 1 deletion
libcelt/mdct.h
src/opus_decoder.c
+0
-2
0 additions, 2 deletions
src/opus_decoder.c
src/opus_encoder.c
+2
-1
2 additions, 1 deletion
src/opus_encoder.c
with
4 additions
and
4 deletions
libcelt/mdct.c
+
1
−
0
View file @
66c612ef
...
...
@@ -99,6 +99,7 @@ void clt_mdct_clear(mdct_lookup *l)
#endif
/* CUSTOM_MODES */
/* Forward MDCT trashes the input array */
void
clt_mdct_forward
(
const
mdct_lookup
*
l
,
kiss_fft_scalar
*
in
,
kiss_fft_scalar
*
restrict
out
,
const
opus_val16
*
window
,
int
overlap
,
int
shift
,
int
stride
)
{
...
...
This diff is collapsed.
Click to expand it.
libcelt/mdct.h
+
1
−
1
View file @
66c612ef
...
...
@@ -55,7 +55,7 @@ typedef struct {
int
clt_mdct_init
(
mdct_lookup
*
l
,
int
N
,
int
maxshift
);
void
clt_mdct_clear
(
mdct_lookup
*
l
);
/** Compute a forward MDCT and scale by 4/N */
/** Compute a forward MDCT and scale by 4/N
, trashes the input array
*/
void
clt_mdct_forward
(
const
mdct_lookup
*
l
,
kiss_fft_scalar
*
in
,
kiss_fft_scalar
*
out
,
const
opus_val16
*
window
,
int
overlap
,
int
shift
,
int
stride
);
...
...
This diff is collapsed.
Click to expand it.
src/opus_decoder.c
+
0
−
2
View file @
66c612ef
...
...
@@ -39,8 +39,6 @@
#include
"modes.h"
#include
"silk_API.h"
#define MAX_PACKET (1275)
/* Make sure everything's aligned to 4 bytes (this may need to be increased
on really weird architectures) */
static
inline
int
align
(
int
i
)
...
...
This diff is collapsed.
Click to expand it.
src/opus_encoder.c
+
2
−
1
View file @
66c612ef
...
...
@@ -425,7 +425,7 @@ int opus_encode(OpusEncoder *st, const opus_int16 *pcm, int frame_size,
st
->
silk_mode
.
maxInternalSampleRate
=
16000
;
/* Call SILK encoder for the low band */
nBytes
=
max_data_bytes
-
1
;
nBytes
=
IMIN
(
1275
,
max_data_bytes
-
1
)
;
if
(
prefill
)
{
int
zero
=
0
;
...
...
@@ -515,6 +515,7 @@ int opus_encode(OpusEncoder *st, const opus_int16 *pcm, int frame_size,
}
}
nb_compr_bytes
=
IMIN
(
1275
,
nb_compr_bytes
);
ec_enc_shrink
(
&
enc
,
nb_compr_bytes
);
}
else
{
nb_compr_bytes
=
0
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment