Skip to content

Commit bd72a81

Browse files
committed
[TSDemuxer] Revert removal of AUDs preceding AVC Header
Reverts commit 13ce46c
1 parent 9f558c7 commit bd72a81

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

src/org/mangui/hls/demux/TSDemuxer.as

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,6 @@ package org.mangui.hls.demux {
102102

103103
/** Transmux the M2TS file into an FLV file. **/
104104
public function TSDemuxer(callback_audioselect : Function, callback_progress : Function, callback_complete : Function, callback_videometadata : Function, audioOnly : Boolean) {
105-
_avcc = null;
106105
_curAudioPES = null;
107106
_curVideoPES = null;
108107
_curId3PES = null;
@@ -127,6 +126,7 @@ package org.mangui.hls.demux {
127126
/** append new TS data */
128127
public function append(data : ByteArray) : void {
129128
if (_dataVector == null) {
129+
_avcc = null;
130130
_dataVector = new Vector.<ByteArray>();
131131
_dataComplete = false;
132132
_readPosition = 0;
@@ -461,15 +461,7 @@ package org.mangui.hls.demux {
461461
/* push current data into video tag, if any */
462462
_curVideoTag.push(_curNalUnit, 0, _curNalUnit.length);
463463
}
464-
// only push current tag if AVC HEADER has been pushed already
465-
if(_avcc) {
466-
_tags.push(_curVideoTag);
467-
}
468-
CONFIG::LOGGING {
469-
if(!_avcc) {
470-
Log.warn("TS: discarding video tag, as AVC HEADER not found yet, fragment not starting with I-Frame ?");
471-
}
472-
}
464+
_tags.push(_curVideoTag);
473465
}
474466
_curNalUnit = new ByteArray();
475467
_curVideoTag = new FLVTag(FLVTag.AVC_NALU, pes.pts, pes.dts, false);

0 commit comments

Comments
 (0)