[asterisk-users] length voicefile
Arjan Kroon | Mobillion
Arjan.Kroon at mobillion.nl
Wed May 28 05:00:13 CDT 2008
Hi,
I found the solution through a system command
shninfo ${REDORDED_FILE} |awk 'NR==4 {print $2 }'
then you get the length of the wav voicefile.
Tx,
Arjan Kroon
________________________________
From: asterisk-users-bounces at lists.digium.com
[mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Arjan
Kroon | Mobillion
Sent: woensdag 28 mei 2008 11:15
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] length voicefile
Hi,
The recorded format is wav.
But in the application I don't use AGI for recording a voicefile.
Grt,
Arjan Kroon
________________________________
From: asterisk-users-bounces at lists.digium.com
[mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Tim Panton
Sent: woensdag 28 mei 2008 10:45
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] length voicefile
On 28 May 2008, at 08:21, Arjan Kroon | Mobillion wrote:
Hi,
Is there a way to get the length (in seconds) of a voicefile which is
record with the command Record()?
Well, if you know the format, you can do some maths on the length of the
file.
RECORDED_FILE is set to the filename, so a exec'ing shell script should
do the trick.
AGI seems to return the length of the recording in 'offset'
http://www.voip-info.org/wiki/view/record+file
But app_record seems not to.
Tim.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20080528/bad42250/attachment.htm
More information about the asterisk-users
mailing list