[asterisk-dev] playback application sends a short frame at end of file

Kevin P. Fleming kpfleming at digium.com
Mon Jul 30 10:49:32 CDT 2012


On 07/30/2012 10:32 AM, Paul Albrecht wrote:

> The playback application sends a short frame at the end of file if the
> sound file isn't a multiple of the 160 of samples. Is that a bug or a
> feature?

Neither. It is sending what it was told to send. If your endpoints are 
particular about receiving consistently-sized frames, then you'll need 
to pad your recording files to an appropriate size. This can be tricky, 
though, since channels can negotiate varying frame sizes, and finding a 
multiple that makes sense for all of them might be more work than you'd 
care to do.

In the end, though, it should not matter: any reasonably well 
implemented endpoint will accept variable-sized frames, as long as they 
aren't any larger than what it has stated its maximum to be (if it did so).

-- 
Kevin P. Fleming
Digium, Inc. | Director of Software Technologies
Jabber: kfleming at digium.com | SIP: kpfleming at digium.com | Skype: kpfleming
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
Check us out at www.digium.com & www.asterisk.org



More information about the asterisk-dev mailing list