|
2#
楼主 |
发表于 2008-7-30 13:33:19
|
只看该作者
data.ws的内容是:
;WSRData 2 1
send buf0 128
"OPTIONS rtsp://192.168.0.58:554/sh.mpg RTSP/1.0\r\n"
"CSeq: 1\r\n"
"User-Agent: VLC media player (LIVE555 Streaming Media v2007.02.20)\r\n"
"\r\n"
recv buf1 115
"RTSP/1.0 200 Ok\r\n"
"Cseq: 1\r\n"
"Server: VLC Server\r\n"
"Public: DESCRIBE, SETUP, TEARDOWN, PLAY, PAUSE\r\n"
"Content-Length: 0\r\n"
"\r\n"
send buf2 154
"DESCRIBE rtsp://192.168.0.58:554/sh.mpg RTSP/1.0\r\n"
"CSeq: 2\r\n"
"Accept: application/sdp\r\n"
"User-Agent: VLC media player (LIVE555 Streaming Media v2007.02.20)\r\n"
"\r\n"
recv buf3 339
"RTSP/1.0 200 OK\r\n"
"Content-type: application/sdp\r\n"
"Server: VLC Server\r\n"
"Content-Length: 214\r\n"
"Cseq: 2\r\n"
"Cache-Control: no-cache\r\n"
"\r\n"
"v=0\r\n"
"o=- 1217380334398509 2 IN IP4 192.168.0.58\r\n"
"c=IN IP4 0.0.0.0\r\n"
"t=0 0\r\n"
"a=tool:vlc 0.8.6c\r\n"
"a=range:npt=0-206.889\r\n"
"m=video 0 RTP/AVP 33\r\n"
"a=rtpmap:33 MP2T/90000\r\n"
"a=control:rtsp://192.168.0.58:554/sh.mpg/trackID=0\r\n"
send buf4 11
"hostIdTest"
"\x00"
recv buf5 11
"hostIdTest"
"\x00"
send buf6 186
"SETUP rtsp://192.168.0.58:554/sh.mpg/trackID=0 RTSP/1.0\r\n"
"CSeq: 3\r\n"
"Transport: RTP/AVP;unicast;client_port=1462-1463\r\n"
"User-Agent: VLC media player (LIVE555 Streaming Media v2007.02.20)\r\n"
"\r\n"
recv buf7 159
"RTSP/1.0 200 OK\r\n"
"Transport: RTP/AVP/UDP;client_port=1462-1463\r\n"
"Server: VLC Server\r\n"
"Content-Length: 0\r\n"
"Cseq: 3\r\n"
"Cache-Control: no-cache\r\n"
"Session: 1804289383\r\n"
"\r\n"
send buf8 165
"PLAY rtsp://192.168.0.58:554/sh.mpg RTSP/1.0\r\n"
"CSeq: 4\r\n"
"Session: 1804289383\r\n"
"Range: npt=0.000-\r\n"
"User-Agent: VLC media player (LIVE555 Streaming Media v2007.02.20)\r\n"
"\r\n"
recv buf9 123
"RTSP/1.0 200 OK\r\n"
"Server: VLC Server\r\n"
"Content-Length: 0\r\n"
"Cseq: 4\r\n"
"Cache-Control: no-cache\r\n"
"Session: 1804289383;timeout=5\r\n"
"\r\n"
Action的内容是:
/*********************************************************************
* Created by Mercury Interactive Windows Sockets Recorder
*
* Created on: Wed Jul 30 10:05:49
*********************************************************************/
#include "lrs.h"
Action()
{
lrs_create_socket("socket0", "TCP", "LocalHost=0", "RemoteHost=192.168.0.58:554", LrsLastArg);
lrs_send("socket0", "buf0", LrsLastArg);
lrs_receive("socket0", "buf1", LrsLastArg);
lrs_send("socket0", "buf2", LrsLastArg);
lrs_receive("socket0", "buf3", LrsLastArg);
lrs_create_socket("socket1", "UDP", "LocalHost=15947", LrsLastArg);
lrs_send("socket1", "buf4", "TargetSocket=reserved-multicast-range-NOT-delegated.example.com:15947", LrsLastArg);
lrs_receive("socket1", "buf5", LrsLastArg);
lrs_close_socket("socket1");
lrs_send("socket0", "buf6", LrsLastArg);
lrs_receive("socket0", "buf7", LrsLastArg);
lrs_send("socket0", "buf8", LrsLastArg);
lrs_create_socket("socket2", "UDP", "LocalHost=0", LrsLastArg);
lrs_receive("socket0", "buf9", LrsLastArg);
lrs_receive("socket2", "buf10", LrsLastArg);
lrs_create_socket("socket3", "UDP", "LocalHost=1463", LrsLastArg);
lrs_send("socket3", "buf11", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf12", LrsLastArg);
lrs_send("socket3", "buf13", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf14", LrsLastArg);
lrs_send("socket3", "buf15", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf16", LrsLastArg);
lrs_send("socket3", "buf17", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf18", LrsLastArg);
lrs_send("socket3", "buf19", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf20", LrsLastArg);
lrs_send("socket3", "buf21", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf22", LrsLastArg);
lrs_send("socket3", "buf23", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf24", LrsLastArg);
lrs_send("socket3", "buf25", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf26", LrsLastArg);
lrs_send("socket3", "buf27", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf28", LrsLastArg);
lrs_send("socket3", "buf29", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf30", LrsLastArg);
lrs_send("socket3", "buf31", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf32", LrsLastArg);
lrs_send("socket3", "buf33", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf34", LrsLastArg);
lrs_send("socket3", "buf35", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf36", LrsLastArg);
lrs_send("socket3", "buf37", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf38", LrsLastArg);
lrs_send("socket3", "buf39", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf40", LrsLastArg);
lrs_send("socket3", "buf41", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf42", LrsLastArg);
lrs_send("socket3", "buf43", "TargetSocket=192.168.0.58:1", LrsLastArg);
lrs_receive("socket2", "buf44", LrsLastArg);
return 0;
} |
|