Skip to content

Commit

Permalink
update dist
Browse files Browse the repository at this point in the history
related to #1239
  • Loading branch information
mangui committed Jun 29, 2017
1 parent 19828f4 commit c244e78
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 28 deletions.
28 changes: 17 additions & 11 deletions dist/hls.js
Original file line number Diff line number Diff line change
Expand Up @@ -2084,7 +2084,7 @@ var AudioTrackController = function (_EventHandler) {
// loop through available audio tracks and autoselect default if needed
var id = 0;
tracks.forEach(function (track) {
if (track.default) {
if (track.default && !defaultFound) {
_this2.audioTrack = id;
defaultFound = true;
return;
Expand Down Expand Up @@ -9296,10 +9296,21 @@ var TSDemuxer = function () {
avcSample = this.avcSample,
push,
spsfound = false,
i;
i,
pushAccesUnit = this.pushAccesUnit.bind(this),
createAVCSample = function createAVCSample(key, pts, dts, debug) {
return { key: key, pts: pts, dts: dts, units: [], debug: debug };
};
//free pes.data to save up some memory
pes.data = null;

// if new NAL units found and last sample still there, let's push ...
// this helps parsing streams with missing AUD
if (avcSample && units.length) {
pushAccesUnit(avcSample, track);
avcSample = this.avcSample = createAVCSample(false, pes.pts, pes.dts, '');
}

units.forEach(function (unit) {
switch (unit.type) {
//NDR
Expand Down Expand Up @@ -9329,7 +9340,7 @@ var TSDemuxer = function () {
push = true;
// handle PES not starting with AUD
if (!avcSample) {
avcSample = _this.avcSample = _this._createAVCSample(true, pes.pts, pes.dts, '');
avcSample = _this.avcSample = createAVCSample(true, pes.pts, pes.dts, '');
}
if (debug) {
avcSample.debug += 'IDR ';
Expand Down Expand Up @@ -9452,9 +9463,9 @@ var TSDemuxer = function () {
case 9:
push = false;
if (avcSample) {
_this.pushAccesUnit(avcSample, track);
pushAccesUnit(avcSample, track);
}
avcSample = _this.avcSample = _this._createAVCSample(false, pes.pts, pes.dts, debug ? 'AUD ' : '');
avcSample = _this.avcSample = createAVCSample(false, pes.pts, pes.dts, debug ? 'AUD ' : '');
break;
// Filler Data
case 12:
Expand All @@ -9474,15 +9485,10 @@ var TSDemuxer = function () {
});
// if last PES packet, push samples
if (last && avcSample) {
this.pushAccesUnit(avcSample, track);
pushAccesUnit(avcSample, track);
this.avcSample = null;
}
}
}, {
key: '_createAVCSample',
value: function _createAVCSample(key, pts, dts, debug) {
return { key: key, pts: pts, dts: dts, units: [], debug: debug };
}
}, {
key: '_insertSampleInOrder',
value: function _insertSampleInOrder(arr, data) {
Expand Down
6 changes: 3 additions & 3 deletions dist/hls.js.map

Large diffs are not rendered by default.

26 changes: 16 additions & 10 deletions dist/hls.light.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions dist/hls.light.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/hls.light.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/hls.min.js

Large diffs are not rendered by default.

0 comments on commit c244e78

Please sign in to comment.