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
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
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
Marcus Asteborg
Opus
Commits
d2124cdf
Commit
d2124cdf
authored
13 years ago
by
Jean-Marc Valin
Browse files
Options
Downloads
Patches
Plain Diff
Loss rate adaptation for the CELT layer
parent
fa869134
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
celt
+1
-1
1 addition, 1 deletion
celt
src/opus_encoder.c
+7
-2
7 additions, 2 deletions
src/opus_encoder.c
with
8 additions
and
3 deletions
celt
@
cb73e5ca
Subproject commit
d25dd2bff9f111fcc8d2de802c1cca337db27873
Subproject commit
cb73e5ca62f93f530e65b244cf52f905a727d04d
This diff is collapsed.
Click to expand it.
src/opus_encoder.c
+
7
−
2
View file @
d2124cdf
...
...
@@ -583,7 +583,10 @@ int opus_encoder_ctl(OpusEncoder *st, int request, ...)
case
OPUS_SET_PACKET_LOSS_PERC_REQUEST
:
{
int
value
=
va_arg
(
ap
,
int
);
if
(
value
<
0
||
value
>
100
)
return
OPUS_BAD_ARG
;
st
->
silk_mode
.
packetLossPercentage
=
value
;
celt_encoder_ctl
(
st
->
celt_enc
,
CELT_SET_LOSS_PERC
(
value
));
}
break
;
case
OPUS_GET_PACKET_LOSS_PERC_REQUEST
:
...
...
@@ -609,7 +612,7 @@ int opus_encoder_ctl(OpusEncoder *st, int request, ...)
{
int
value
=
va_arg
(
ap
,
int
);
if
(
value
>
100
||
value
<
0
)
return
OPUS_BAD_ARG
;
goto
bad_arg
;
st
->
voice_ratio
=
value
;
}
break
;
...
...
@@ -635,9 +638,11 @@ int opus_encoder_ctl(OpusEncoder *st, int request, ...)
fprintf
(
stderr
,
"unknown opus_encoder_ctl() request: %d"
,
request
);
break
;
}
va_end
(
ap
);
return
OPUS_OK
;
bad_arg:
va_end
(
ap
);
return
OPUS_BAD_ARG
;
}
void
opus_encoder_destroy
(
OpusEncoder
*
st
)
...
...
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