[asterisk-users] Asterisk 14 audio quality with remote files

Matthew Jordan mjordan at digium.com
Sat May 20 19:33:53 CDT 2017


On Tue, May 16, 2017 at 3:00 PM, Tiago Ferreira
<cyberneticrevolution at gmail.com> wrote:
> Anyone?
> I tried converting the file to g722 with ffmpeg and got the same result.
>
> regards
> Tiago
> On 12-05-2017 12:10, Tiago Ferreira wrote:
>
> Hello everyone,
>
> I am using the Asterisk REST API in order to establish a call to an endpoint
> and to send over a remote file (HTTP).
> The issue is that I am experiencing an audio quality issue.
> I have tried encoding the file differently, but everytime Asterisk is
> cutting the audio frequencies above 4Khz.
> The call is established with G.722 and the audio file is mono 16Khz 16 bit
> sln16 extension.
> What can I do to improve the sound quality? Is there any way to not have
> asterisk cut the audio frequencies?
>

The remote playback option doesn't manipulate the audio file in any
way that is different than playing the file back from disk. At a high
level, the cURL'd file is stored in a temporary location, mapped to
the URL for future referencing, and handed off to the file core. At
that point, it's the same as playing back any media file with a known
format, where that format - just like all media files in Asterisk - is
indicated by the file extension.

What extension is the file? What format does Asterisk think the file
is? It should tell you that when your verbosity is 3 or higher:

ast_verb(3, "<%s> Playing '%s.%s' (language '%s')\n",
ast_channel_name(chan), filename,
ast_format_get_name(ast_channel_writeformat(chan)), preflang ?
preflang : "default");

Matt

-- 
Matthew Jordan
Digium, Inc. | CTO
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
Check us out at: http://digium.com & http://asterisk.org



More information about the asterisk-users mailing list