gpt4 book ai didi

java - Asterisk - 如何为音频文件添加书签

转载 作者:太空宇宙 更新时间:2023-11-04 12:34:26 24 4
gpt4 key购买 nike

我需要书签音频文件流。

如何传输文件但不从 0 开始?比如从 1 分钟开始或者类似的事情。任何人请给我一个提示。编辑:我怎样才能获得播放的部分的字节?因为 Offset:开始播放的偏移字节,所以我需要获取书签字节。

最佳答案

您拥有允许带偏移播放的应用程序 ControlPlayback。

pro-sip*CLI> core show application ControlPlayback 

-= Info about application 'ControlPlayback' =-

[Synopsis]
Play a file with fast forward and rewind.

[Description]
This application will play back the given <filename>.
It sets the following channel variables upon completion:
${CPLAYBACKSTATUS}: Contains the status of the attempt as a text string
SUCCESS
USERSTOPPED
ERROR
${CPLAYBACKOFFSET}: Contains the offset in ms into the file where playback
was at when it stopped. '-1' is end of file.
${CPLAYBACKSTOPKEY}: If the playback is stopped by the user this variable
contains the key that was pressed.

[Syntax]
ControlPlayback(filename[,skipms[,ff[,rew[,stop[,pause[,restart[,options]]]]]]])

[Arguments]
skipms
This is number of milliseconds to skip when rewinding or fast-fo
rwarding.
ff
Fast-forward when this DTMF digit is received. (defaults to '#')
rew
Rewind when this DTMF digit is received. (defaults to '*')
stop
Stop playback when this DTMF digit is received.
pause
Pause playback when this DTMF digit is received.
restart
Restart playback when this DTMF digit is received.
options
o(time):
time - Start at <time> ms from the beginning of the file.



[See Also]
Not available

关于java - Asterisk - 如何为音频文件添加书签,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37477787/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com