|
录制脚本后进行回放提示:
Error occured while decoding RTMP binary message
脚本如下:
Action()
{
flex_rtmp_connect("connect_step0",
"Host=10.1.0.92:1936",
"Snapshot=tRTMP1.inf",
"ConnectionID=20",
MESSAGE,
"DataType=command message amf0",
"ChunkStreamID=3",
"MessageStreamID=0",
"Argument=<arguments><string>connect</string><number>1</number><object>"
"<string name=\"app\">live/_definst_</string><string name=\"flashVer\""
">WIN 11,4,402,287</string><string name=\"swfUrl\">http://10.1.0.92/cms"
"/swf/StrobeMediaPlayback.swf</string><string name=\"tcUrl\">rtmp://"
"10.1.0.92:1936/live/_definst_</string><boolean name=\"fpad\">false</"
"boolean><number name=\"capabilities\">239</number><number name=\""
"audioCodecs\">3575</number><number name=\"videoCodecs\">252</number>"
"<number name=\"videoFunction\">1</number><string name=\"pageUrl\" "
"rawData=\"1\""
">\\x68\\x74\\x74\\x70\\x3A\\x2F\\x2F\\x31\\x30\\x2E\\x31\\x2E\\x30\\x2"
"E\\x39\\x32\\x2F\\x63\\x6D\\x73\\x2F\\x6D\\x65\\x64\\x69\\x61\\x21\\x7"
"0\\x61\\x6C\\x79\\x65\\x72\\x2E\\x61\\x63\\x74\\x69\\x6F\\x6E\\x3F\\x7"
"0\\x61\\x6C\\x79\\x65\\x72\\x2E\\x6D\\x65\\x64\\x69\\x61\\x54\\x79\\x7"
"0\\x65\\x3D\\x4C\\x49\\x56\\x45\\x26\\x70\\x61\\x6C\\x79\\x65\\x72\\x2"
"E\\x6D\\x65\\x64\\x69\\x61\\x49\\x44\\x3D\\x37\\x35</string><number "
"name=\"objectEncoding\">3</number></object></arguments>",
LAST);
//flex_rtmp_receive("recv_step0",
//"ConnectionID=20",
//"Snapshot=tRTMP2.inf",
// CHANNEL,
// "ChunkStreamID=2",
// CHANNEL,
// "ChunkStreamID=2",
// CHANNEL,
// "ChunkStreamID=2",
// CHANNEL,
// "ChunkStreamID=2",
// CHANNEL,
// "ChunkStreamID=3",
// LAST);
flex_rtmp_send("send_step0",
"ConnectionID=20",
"Snapshot=tRTMP3.inf",
MESSAGE,
"DataType=window acknowledgment size",
"WindowSize=2500000",
LAST);
flex_rtmp_send("send_step1",
"ConnectionID=20",
"Snapshot=tRTMP4.inf",
MESSAGE,
"DataType=command message amf3",
"ChunkStreamID=3",
"MessageStreamID=0",
"Argument=<arguments><string>createStream</string><number>2</number>"
"<null/></arguments>",
MESSAGE,
"DataType=user control message",
"EventType=set buffer length",
"MessageStreamID=0",
"BufferLength=100",
LAST);
// flex_rtmp_receive("recv_step1",
// "ConnectionID=20",
// "Snapshot=tRTMP5.inf",
// CHANNEL,
// "ChunkStreamID=3",
// LAST);
flex_rtmp_send("send_step2",
"ConnectionID=20",
"Snapshot=tRTMP6.inf",
MESSAGE,
"DataType=command message amf3",
"ChunkStreamID=8",
"MessageStreamID=1",
"Argument=<arguments><string>play</string><number>0</number><null/>"
"<string>live-4275147918.sdp</string><number>-1000</number><number"
">-1000</number></arguments>",
MESSAGE,
"DataType=user control message",
"EventType=set buffer length",
"MessageStreamID=1",
"BufferLength=100",
LAST);
flex_rtmp_receive_stream("recv_stream_step0",
"ConnectionID=20",
"Snapshot=tRTMP7.inf",
LAST);
return 0;
} |
|