Browse Source

Use 3-byte end object tag

Drop the extra null byte when closing an "ecmascript array" in the metadata tag. The spec specifies a 3 byte tag and I'm not sure how the 4-byte version managed to work in practice. This makes the output differ significantly from the original actionscript version of the code but the converted video still plays back without any issues.
pull/80/head
David LaPalomento 12 years ago
parent
commit
cfb6c4198f
  1. 6
      src/flv-tag.js

6
src/flv-tag.js

@ -268,10 +268,8 @@ hls.FlvTag = function(type, extraData) {
this.position++;
this.view.setUint32(this.position, adHoc);
this.position = this.length;
// this.bytes.set([0, 0, 9], this.position);
// this.position += 3;
this.view.setUint32(this.position, 0x09); // End Data Tag
this.position += 4;
this.bytes.set([0, 0, 9], this.position);
this.position += 3; // End Data Tag
this.length = this.position;
break;
}

Loading…
Cancel
Save