English 中文(简体)
利用RPP流中的FFMPEG(PCAP)
原标题:Decoding G.729 using FFMPEG from RTP stream (PCAP)

我有包含RPT数据的文件,然后是G.729代码C的录音。 是否有办法通过将其推入FFMPEG来规范这一流? 这很可能意味着,我不得不从PCAP文档中提取RTP有效载荷数据,然后将数据转给FFMPEG。

任何准则和联络点都受到高度赞赏。

最佳回答

这一回答不需要<条码>ffmpeg,但我假定你真心实意地关注如何提取音响。 查阅 如何将G729编码放在电线上......

  1. Intelshark, use menu “Statistics -> RTP -> show All Petros. 选择理想的溪流和新闻“分析”。

  2. 在接下来的方言屏幕上,新闻“Save Pay......”。 备选案文2: Format = raw. and Channel = forward。 姓名:my_input.raw

  3. Convert the .raw file to .pcm Format using the Open G.729 decoder. 辛塔克斯:va_g729_decoder.exe 我的投稿,摘自我的投稿。 或用于六氯环己烷:wine va_g729_decoder.exe 我的投稿,摘自我的投稿。

  4. <代码>pcm文档中包含16-bit Linear PCM样本,标有8000 Hz. Note,每个样本均采用小型加拿大格式。 为了转换成.au格式,你需要做的是提前24小时的负责人,并将每份金字节样本转换为网络顺序(或Big-Endian)。 以下<代码>perl 文字将作.。

USAGE: perl pcm2au.pl [my_inputFile] [my_outputFile]

$usage = "Usage:  perl $0 [Source PCM File] [Destination AU File]  ";

$my_inputFile = shift or die $usage;
$my_outputFile = shift or die $usage;

open(INPUTFILE, "$my_inputFile") or die "Unable to open file: $!
";
binmode INPUTFILE;

open(OUTPUTFILE, "> $my_outputFile") or die "Unable to open file: $!
";
binmode OUTPUTFILE;

###################################
# Write the AU header
###################################

print OUTPUTFILE  ".snd";

$foo = pack("CCCC", 0,0,0,24);
print OUTPUTFILE  $foo;

$foo = pack("CCCC", 0xff,0xff,0xff,0xff);
print OUTPUTFILE  $foo;

$foo = pack("CCCC", 0,0,0,3);
print OUTPUTFILE  $foo;

$foo = pack("CCCC", 0,0,0x1f,0x40);
print OUTPUTFILE  $foo;

$foo = pack("CCCC", 0,0,0,1);
print OUTPUTFILE  $foo;

#############################
# swap the PCM samples
#############################

while (read(INPUTFILE, $inWord, 2) == 2) {

    @bytes   = unpack( CC , $inWord);
    $outWord = pack( CC , $bytes[1], $bytes[0]);
    print OUTPUTFILE  $outWord;
}

close(OUTPUTFILE);
close(INPUTFILE);
问题回答

你可以采取的步骤是:

  1. extract the RTP/RTCP packets: with a tool like rtpbreak: http://dallachiesa.com/code/rtpbreak/
  2. generate (with and editor) a sdp file to be passed at ffmpeg or mplayer or vlan
  3. launch ffmpeg (or mplayer or vlan) with SDP file
  4. stream RTP/RTCP packets at ffmpeg with rtpplay: http://www.cs.columbia.edu/irt/software/rtptools/

但是,如果你的目标是“只”cap光灯(RTP G729代码c),那么你可以使用录像带。

va_g729_decoder.exe 仅为赢家工作。 大约64个轨道窗口是什么?





相关问题
C# Networking API s [closed]

Lately I ve been looking for a good networking API i could possibly use and/or reference some of the code within, but i have mere luck searching for some on Google/Bing. Hopefully somebody here has ...

Listen to a port that is in use [duplicate]

Possible Duplicate: Get connecting IP from specified ports that using by other program. If a port is used by a program, is there any way I can listen that port and get the connected IP on that ...

Twisted Spread suitable for multiplayer racing sim?

Do you think that Twisted Spread may be suitable (in terms of performance) for a multiplayer racing simulator? The rest of the application is based on Python-Ogre. Can Perspective Broker run upon (...

Optimizing a LAN server for a game

I m the network programmer on a school game project. We want to have up to 16 players at once on a LAN. I am using the Server-Client model and am creating a new thread per client that joins. ...

multicast ip address - blocked in call to recvfrom

i am writing a simple multicast application. i intend to run it on localhost. i have done the following: char *maddr; . . . sendfd = socket(...); struct sockaddr_in sasend; sasend.sin_family = ...

Java HTTPAUTH

我试图把桌面应用程序连接起来,我是同D.icio.us api @ Delicious Alan书写的,简单地向他们提供我的用户名和密码,并请他把书记上写给我......。