[Asterisk-code-review] channel.c: Allow generic plc then channel formats are equal (asterisk[13])
Richard Mudgett
asteriskteam at digium.com
Mon Mar 19 10:58:46 CDT 2018
Richard Mudgett has posted comments on this change. ( https://gerrit.asterisk.org/8553 )
Change subject: channel.c: Allow generic plc then channel formats are equal
......................................................................
Patch Set 1: Code-Review-1
(4 comments)
Here's your -1 so as not to dissappoint you. :)
https://gerrit.asterisk.org/#/c/8553/1/main/channel.c
File main/channel.c:
https://gerrit.asterisk.org/#/c/8553/1/main/channel.c@6571
PS1, Line 6571: * even if the formats are teh same.
It is spelled: the
:)
https://gerrit.asterisk.org/#/c/8553/1/main/channel.c@6573
PS1, Line 6573: if ((ast_format_cmp(best_dst_fmt, best_src_fmt) == AST_FORMAT_CMP_NOT_EQUAL
: || (ast_opt_generic_plc && ast_opt_generic_plc_on_equal_codecs))
: && (ast_opt_generic_plc || ast_opt_transcode_via_slin)) {
This logic can be simplified since you force ast_opt_generic_plc_on_equal_codecs to false when ast_opt_generic_plc is false.
if (ast_opt_generic_plc_on_equal_codecs
|| (ast_format_cmp(best_dst_fmt, best_src_fmt) == AST_FORMAT_CMP_NOT_EQUAL
&& (ast_opt_generic_plc || ast_opt_transcode_via_slin))) {
}
https://gerrit.asterisk.org/#/c/8553/1/main/channel.c@6576
PS1, Line 6576: int use_slin = (ast_format_cache_is_slinear(best_src_fmt)
: || ast_format_cache_is_slinear(best_dst_fmt)) ? 1 : 0;
We need to force translation through signed linear no matter how many translation steps there are otherwise when ast_opt_generic_plc_on_equal_codecs is enabled.
int use_slin = (ast_format_cache_is_slinear(best_src_fmt)
|| ast_format_cache_is_slinear(best_dst_fmt))
? 1 : ast_opt_generic_plc_on_equal_codecs;
https://gerrit.asterisk.org/#/c/8553/1/main/channel.c@7671
PS1, Line 7671: }
: else if (!strcasecmp(var->name, "genericplc_on_equal_codecs")) {
} else if () {
--
To view, visit https://gerrit.asterisk.org/8553
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: comment
Gerrit-Change-Id: I0577026a179dea34232e63123254b4e0508378f4
Gerrit-Change-Number: 8553
Gerrit-PatchSet: 1
Gerrit-Owner: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>
Gerrit-Comment-Date: Mon, 19 Mar 2018 15:58:46 +0000
Gerrit-HasComments: Yes
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180319/da01ae05/attachment.html>
More information about the asterisk-code-review
mailing list