Merge branch 'development' into LTS_development

# Conflicts:
#	src/output/output_ts_base.cpp
This commit is contained in:
Thulinma 2015-08-04 11:35:20 +02:00
commit 76ebcd4735
3 changed files with 5 additions and 7 deletions

View file

@ -249,6 +249,7 @@ namespace Mist {
}
seek(from);
ts_from = from;
lastVid = from * 90;
H.SetHeader("Content-Type", "video/mp2t");

View file

@ -5,6 +5,7 @@ namespace Mist {
packCounter=0;
haveAvcc = false;
haveHvcc = false;
ts_from = 0;
until=0xFFFFFFFFFFFFFFFFull;
setBlocking(true);
sendRepeatingHeaders = false;
@ -103,7 +104,7 @@ namespace Mist {
while (currPack <= splitCount){
unsigned int alreadySent = 0;
bs = TS::Packet::getPESVideoLeadIn((currPack != splitCount ? watKunnenWeIn1Ding : dataLen+extraSize - currPack*watKunnenWeIn1Ding), thisPacket.getTime() * 90, thisPacket.getInt("offset") * 90, !currPack);
bs = TS::Packet::getPESVideoLeadIn((currPack != splitCount ? watKunnenWeIn1Ding : dataLen+extraSize - currPack*watKunnenWeIn1Ding), (thisPacket.getTime() - ts_from) * 90, thisPacket.getInt("offset") * 90, !currPack);
fillPacket(bs.data(), bs.size());
if (!currPack){
if (myMeta.tracks[thisPacket.getTrackId()].codec == "H264" && (dataPointer[4] & 0x1f) != 0x09){
@ -179,13 +180,8 @@ namespace Mist {
if (appleCompat){
tempTime = 0;// myMeta.tracks[thisPacket.getTrackId()].rate / 1000;
}else{
tempTime = thisPacket.getTime() * 90;
tempTime = (thisPacket.getTime() - ts_from) * 90;
}
///\todo stuur 70ms aan audio per PES pakket om applecompat overbodig te maken.
//static unsigned long long lastSent=thisPacket.getTime() * 90;
//if( (thisPacket.getTime() * 90)-lastSent >= 70*90 ){
// lastSent=(thisPacket.getTime() * 90);
//}
bs = TS::Packet::getPESAudioLeadIn(tempLen, tempTime);// myMeta.tracks[thisPacket.getTrackId()].rate / 1000 );
fillPacket(bs.data(), bs.size());
if (myMeta.tracks[thisPacket.getTrackId()].codec == "AAC"){

View file

@ -30,6 +30,7 @@ namespace Mist {
MP4::HVCC hvccbox;
/*LTS-END*/
bool sendRepeatingHeaders;
long long unsigned int ts_from;
long long unsigned int until;
long long unsigned int lastVid;
};