b86b25f4 by David LaPalomento

Merge pull request #106 from gutworth/ts-dts

write dts to the timestamp part of the flv header, not pts
2 parents c4a60268 c3b6d369
...@@ -289,10 +289,10 @@ hls.FlvTag = function(type, extraData) { ...@@ -289,10 +289,10 @@ hls.FlvTag = function(type, extraData) {
289 this.bytes[ 2] = (len & 0x0000FF00) >>> 8; 289 this.bytes[ 2] = (len & 0x0000FF00) >>> 8;
290 this.bytes[ 3] = (len & 0x000000FF) >>> 0; 290 this.bytes[ 3] = (len & 0x000000FF) >>> 0;
291 // write the Timestamp 291 // write the Timestamp
292 this.bytes[ 4] = (this.pts & 0x00FF0000) >>> 16; 292 this.bytes[ 4] = (this.dts & 0x00FF0000) >>> 16;
293 this.bytes[ 5] = (this.pts & 0x0000FF00) >>> 8; 293 this.bytes[ 5] = (this.dts & 0x0000FF00) >>> 8;
294 this.bytes[ 6] = (this.pts & 0x000000FF) >>> 0; 294 this.bytes[ 6] = (this.dts & 0x000000FF) >>> 0;
295 this.bytes[ 7] = (this.pts & 0xFF000000) >>> 24; 295 this.bytes[ 7] = (this.dts & 0xFF000000) >>> 24;
296 // write the StreamID 296 // write the StreamID
297 this.bytes[ 8] = 0; 297 this.bytes[ 8] = 0;
298 this.bytes[ 9] = 0; 298 this.bytes[ 9] = 0;
......