一、

live555\testProgs\testRTSPClient.cpp 测试rtsp命令和数据接收:

1.发送并处理Describe消息

rtspClient->sendDescribeCommand(continueAfterDESCRIBE);

2.发送并处理Setup消息

rtspClient->sendSetupCommand(*scs.subsession, continueAfterSETUP);

3. 创建sink,准备接收媒体数据

scs.subsession->sink =DummySink::createNew(env, *scs.subsession, rtspClient->url());

4.开始播放

scs.subsession->sink->startPlaying(*(scs.subsession->readSource()),

subsessionAfterPlaying, scs.subsession);

5.获取媒体数据

Poll 模式调用getNexFrame获取媒体数据

fSource->getNextFrame(fReceiveBuffer, DUMMY_SINK_RECEIVE_BUFFER_SIZE,

afterGettingFrame,this,

onSourceClosure, this);

VLC 的live555插件也是使用poll模式调用getNexFame 获取媒体数据

日志信息

------------------------------------------------------------------------------------------------------------------------------------

$ ./testRTSPClient rtsp://10.148.6.83:8554/123.mp3

Opening connection to 10.148.6.83, port 8554...

...remote connection opened

Sending request: DESCRIBE rtsp://10.148.6.83:8554/123.mp3 RTSP/1.0

CSeq: 2

User-Agent: ./testRTSPClient (LIVE555 Streaming Media v2013.08.16)

Accept: application/sdp

Received 554 new bytes of response data.

Received a complete DESCRIBE response:

RTSP/1.0 200 OK

CSeq: 2

Date: Thu, Aug 29 2013 08:28:33 GMT

Content-Base: rtsp://10.148.6.83:8554/123.mp3/

Content-Type: application/sdp

Content-Length: 389

v=0

o=- 1377764913366009 1 IN IP4 10.148.6.83

s=MPEG-1 or 2 Audio, streamed by the LIVE555 Media Server

i=123.mp3

t=0 0

a=tool:LIVE555 Streaming Media v2013.04.01

a=type:broadcast

a=control:*

a=range:npt=0-115.984

a=x-qt-text-nam:MPEG-1 or 2 Audio, streamed by the LIVE555 Media Server

a=x-qt-text-inf:123.mp3

m=audio 0 RTP/AVP 14

c=IN IP4 0.0.0.0

b=AS:128

a=control:track1

[URL:"rtsp://10.148.6.83:8554/123.mp3/"]: Got a SDP description:

v=0

o=- 1377764913366009 1 IN IP4 10.148.6.83

s=MPEG-1 or 2 Audio, streamed by the LIVE555 Media Server

i=123.mp3

t=0 0

a=tool:LIVE555 Streaming Media v2013.04.01

a=type:broadcast

a=control:*

a=range:npt=0-115.984

a=x-qt-text-nam:MPEG-1 or 2 Audio, streamed by the LIVE555 Media Server

a=x-qt-text-inf:123.mp3

m=audio 0 RTP/AVP 14

c=IN IP4 0.0.0.0

b=AS:128

a=control:track1

[URL:"rtsp://10.148.6.83:8554/123.mp3/"]: Initiated the "audio/MPA" subsession (client ports 59780-59781)

Sending request: SETUP rtsp://10.148.6.83:8554/123.mp3/track1 RTSP/1.0

CSeq: 3

User-Agent: ./testRTSPClient (LIVE555 Streaming Media v2013.08.16)

Transport: RTP/AVP;unicast;client_port=59780-59781

Received 201 new bytes of response data.

Received a complete SETUP response:

RTSP/1.0 200 OK

CSeq: 3

Date: Thu, Aug 29 2013 08:28:33 GMT

Transport: RTP/AVP;unicast;destination=10.148.6.83;source=10.148.6.83;client_port=59780-59781;server_port=6970-6971

Session: 317A2B2D

[URL:"rtsp://10.148.6.83:8554/123.mp3/"]: Set up the "audio/MPA" subsession (client ports 59780-59781)

[URL:"rtsp://10.148.6.83:8554/123.mp3/"]: Created a data sink for the "audio/MPA" subsession

Sending request: PLAY rtsp://10.148.6.83:8554/123.mp3/ RTSP/1.0

CSeq: 4

User-Agent: ./testRTSPClient (LIVE555 Streaming Media v2013.08.16)

Session: 317A2B2D

Range: npt=0.000-

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 835 bytes.     Presentation time: 1377764913.797714!

Received 186 new bytes of response data.

Received a complete PLAY response:

RTSP/1.0 200 OK

CSeq: 4

Date: Thu, Aug 29 2013 08:28:33 GMT

Range: npt=0.000-

Session: 317A2B2D

RTP-Info: url=rtsp://10.148.6.83:8554/123.mp3/track1;seq=49924;rtptime=3855656678

[URL:"rtsp://10.148.6.83:8554/123.mp3/"]: Started playing session (for up to 117.984000 seconds)...

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 835 bytes.     Presentation time: 1377764913.849856

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 836 bytes.     Presentation time: 1377764913.902100

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 836 bytes.     Presentation time: 1377764913.954344

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 836 bytes.     Presentation time: 1377764914.006588

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 836 bytes.     Presentation time: 1377764914.058832

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 836 bytes.     Presentation time: 1377764914.111087

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 836 bytes.     Presentation time: 1377764914.163331

Stream "rtsp://10.148.6.83:8554/123.mp3/"; audio/MPA:   Received 836 bytes.     Presentation time: 1377764914.215575

live555库安装_live555库的使用总结 | 学步园相关推荐

  1. Python_note8 程序设计方法学+Python第三方库安装+os库

    实例13 体育竞技分析 自顶向下,解决复杂问题的有效方法,将一个小问题表达为若干小问题组成的形式,使用同样方法进一步解决小问题直至可以用计算机简单解决:自底向上 理解自顶向下的设计思维:分而治之:理解 ...

  2. python json库安装_jsonc库的安装以及简单使用

    if 0 1:cpp在linux下的配置 JSON 官方的解释为:JSON 是一种轻量级的数据传输格式. 关于 JSON 更具体的信息,可参见 JSON 官网:http://www.json.org. ...

  3. python urllib库安装_urllib库安装

    ubuntu怎样安装urllib库ubuntu怎样安装urllib库 先看一下ubuntu的软件源里是否有urllib, 如果没有就需要去 官网下载手动安装. 一般在软件的说明文档里有具体的安装方法, ...

  4. python re库安装_python 库安装方法及常用库

    python库安装方法: 方法一:setpu.py 1.下载库压缩包,解压,记录下路径:*:/**/--/ 2.运行cmd,切换到*:/**/--/目录下 3.运行setup.py build 4.然 ...

  5. live555库安装_live555生成库文件

    若需要将live555编译共享库,可以借助config.linux-with-shared-libraries配置文件.首先需要修改配置文件的交叉编译器: 1.在该文件26行处添加 26 CROSS_ ...

  6. live555库安装_live555的编译及使用

    live555是个流媒体C++开源库,VLC的Meida Player就使用了它的API完成的RTSP客户端,由于VLC的SDK没有提供相关record流到视频文件的API,所以我想用过live555 ...

  7. live555库安装_Live555实战之交叉编译live555共享库

    作者:咕唧咕唧liukun321 来自:http://blog.csdn.net/liukun321 能够通过这个链接获得最新的live555源代码:Live555源代码下载 Live555是一个为流 ...

  8. 树莓派B+使用入门RPI库安装wringPi库安装

    最近看看试用一下树莓派进行一些开发操作,于是入手一块Raspberry Pi B+的板子来玩.由于没有显示器,没有备用的键盘和鼠标,所以想到用SSH来控制树莓派,刚开始还很担心已经安装好的操作系统到底 ...

  9. python的numpy库安装_Python库之numpy库的安装教程

    一.numpy简介 NumPy是一个功能强大的Python库,主要用于对多维数组执行计算.NumPy这个词来源于两个单词-- Numerical和Python.NumPy提供了大量的库函数和操作,可以 ...

最新文章

  1. Novas Verdi、Debussy ,Synopsys VCS,Candence NC-Verilog,Mentor Graphics工具介绍
  2. 一文看尽腾讯WE大会:从治愈白血病到地球肿块,再到类脑芯片,烧脑探索“小宇宙”...
  3. pytorch 激活函数
  4. 2019年3月23日
  5. 无意中发现Markdown,最终解放了我
  6. WebGrid Enterprise
  7. java font 字体 隶书_font-style字体设置
  8. 解析GitHub首页3D动画
  9. 2021年口腔正畸行业隐形矫治器专题研究报告
  10. 笔记︱盘点实验科学的三种实验模型(A/B实验、因果推断、强化学习)
  11. About The Idea Of Flipped
  12. Python自动化 requests 库:发送 form-data 格式的 http 请求
  13. [附源码]SSM计算机毕业设计st音乐网站论文JAVA
  14. PDF Expert for mac(专业的PDF编辑器) 中文版
  15. 中考可以使用计算机吗,中考计算机考什么内容
  16. 《遗传算法原理及应用》笔记—进化计算
  17. 智慧树知到期末答案python_2020智慧树知到Python程序设计基础(山东联盟)期末答案...
  18. 《世界是数字的》读书笔记
  19. lenovo thinkpad x1 carbon 无法打开bios解决方法
  20. 佛系内卷人:唯有不争,方得始终

热门文章

  1. 恋爱星座男女配对微信小程序源码
  2. 企业订货系统平台软件源码|移讯云手机下单管理
  3. 线性代数学习笔记(四)——行列式按行展开
  4. 开放式多媒体应用平台OMAP5910双核通讯技术
  5. motoxt 1085 android8,MOTO X XT1085 5.1.1 ROM刷机包
  6. 日语学习 特别篇 各种总结(家庭成员、数字、星期、月份、方位、都道府县等)
  7. 八字起大运php代码,八字排盘示例代码
  8. 2019年北京画室排名前十位有哪些?北京画室口碑版本
  9. 华为网络设备-三层Eth-trunk配置
  10. 【读】AttSum: Joint Learning of Focusing and Summarization with Neural Attention