RTMP edits, HTTP edits...

This commit is contained in:
Thulinma 2011-02-16 23:24:58 +01:00
parent da8567888a
commit 1b34f4584e
2 changed files with 16 additions and 14 deletions

View file

@ -50,20 +50,22 @@ int FlvToFragNum( FLV_Pack * tag ) {
std::string BuildManifest( std::string MetaData, std::string MovieId, int CurrentMediaTime ) { std::string BuildManifest( std::string MetaData, std::string MovieId, int CurrentMediaTime ) {
Interface * temp = new Interface; Interface * temp = new Interface;
std::string Result="<manifest>\n"; sstd::string Result="<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<manifest xmlns=\"http://ns.adobe.com/f4m/1.0\">\n";
Result += " <mimeType>video/mp4</mimeType>\n"; Result += "<id>";
Result += " <streamType>live</streamType>\n";
Result += " <deliveryType>streaming</deliveryType>\n";
Result += " <bootstrapInfo profile=\"named\" id=\"bootstrap1\">\n";
Result += base64_encode(temp->GenerateLiveBootstrap(CurrentMediaTime));
Result += " </bootstrapInfo>\n";
Result += " <media streamId=\"1\" bootstrapInfoId=\"bootstrap1\" url=\"";
Result += MovieId; Result += MovieId;
Result += "/\">"; Result += "</id>\n<mimeType>video/mp4</mimeType>\n";
Result += " <metadata>\n"; Result += "<streamType>live</streamType>\n";
Result += "<deliveryType>streaming</deliveryType>\n";
Result += "<bootstrapInfo profile=\"named\" id=\"bootstrap1\">";
Result += base64_encode(temp->GenerateLiveBootstrap(CurrentMediaTime));
Result += "</bootstrapInfo>\n";
Result += "<media streamId=\"1\" bootstrapInfoId=\"bootstrap1\" url=\"";
Result += MovieId;
Result += "/\">\n";
Result += "<metadata>";
Result += base64_encode(MetaData); Result += base64_encode(MetaData);
Result += " </metadata>\n"; Result += "</metadata>\n";
Result += " </media>\n"; Result += "</media>\n";
Result += "</manifest>\n"; Result += "</manifest>\n";
delete temp; delete temp;
return Result; return Result;

View file

@ -11,8 +11,8 @@ unsigned int getNowMS(){
} }
unsigned int chunk_rec_max = 128; unsigned int chunk_rec_max = 102400;
unsigned int chunk_snd_max = 128; unsigned int chunk_snd_max = 102400;
unsigned int rec_window_size = 0xFA00; unsigned int rec_window_size = 0xFA00;
unsigned int snd_window_size = 1024*500; unsigned int snd_window_size = 1024*500;
unsigned int rec_window_at = 0; unsigned int rec_window_at = 0;