[Asterisk-Dev] fast-forward & rewind

Mike Reiling miker at mac.com
Tue Apr 8 16:56:11 MST 2003


BTW, this doesn't go back/forward by 5 seconds, but you can change 
that.  Look at file.c.  I added the ast_waitstream_fr function.  You 
can change the time in that function.  I will soon be adding that to 
voicemail.conf, so you can change it easier.

--Mike

On Tuesday, April 8, 2003, at 04:20  PM, Jim Gottlieb wrote:

> Hi.  As part of porting a voicemail application from Dialogic to
> Asterisk, we need to give people the ability to rewind or fast-forward
> the message they are listening to.
>
> We allow them to press * or # to rewind or fast-forward five seconds,
> respectively.  However, we could use some hints on how to do this under
> asterisk.
>
> We use ast_streamfile() ast_waitstream() to play the messages, and can
> allow the * or # to interrupt.  We can also use lseek() to seek to a
> certain position in the file, but how do we know where in the file the
> playing was when the user interrupted?
>
> If we can know that, then we can lseek() back or forward from there.
>
> One possibility is to note the time we start playing the file and
> compare it to the time the DTMF interrupt happens, thus giving us a
> good idea of where in the file they were.
>
> Can anyone think of a better way, or is there some ast_ function we're
> not aware of that would help?
>
> Thanks...
> _______________________________________________
> Asterisk-Dev mailing list
> Asterisk-Dev at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-dev
>
--
Mike Reiling
Systems & Network Administrator
SoftCoin, Inc.
2000 Sierra Point Parkway
Brisbane, CA  94005
650-624-3869 - P
650-624-3899 - F

It might look like I'm doing nothing, but at the cellular level I'm 
really quite busy.




More information about the asterisk-dev mailing list