winlin

Merge branch '2.0release' into develop

@@ -403,6 +403,7 @@ Remark: @@ -403,6 +403,7 @@ Remark:
403 ======= 403 =======
404 ## History 404 ## History
405 405
  406 +* v2.0, 2016-08-30, comment the pcr.
406 * v2.0, 2016-08-18, fix [srs-librtmp#4](https://github.com/ossrs/srs-librtmp/issues/4) filter frame. 407 * v2.0, 2016-08-18, fix [srs-librtmp#4](https://github.com/ossrs/srs-librtmp/issues/4) filter frame.
407 * v2.0, 2016-08-10, fix socket timeout for librtmp. 408 * v2.0, 2016-08-10, fix socket timeout for librtmp.
408 * v2.0, 2016-08-08, fix the crash by srs_info log. 409 * v2.0, 2016-08-08, fix the crash by srs_info log.
@@ -480,6 +480,14 @@ int SrsTsContext::encode_pes(SrsFileWriter* writer, SrsTsMessage* msg, int16_t p @@ -480,6 +480,14 @@ int SrsTsContext::encode_pes(SrsFileWriter* writer, SrsTsMessage* msg, int16_t p
480 480
481 // it's ok to set pcr equals to dts, 481 // it's ok to set pcr equals to dts,
482 // @see https://github.com/ossrs/srs/issues/311 482 // @see https://github.com/ossrs/srs/issues/311
  483 + // Fig. 3.18. Program Clock Reference of Digital-Video-and-Audio-Broadcasting-Technology, page 65
  484 + // In MPEG-2, these are the "Program Clock Refer- ence" (PCR) values which are
  485 + // nothing else than an up-to-date copy of the STC counter fed into the transport
  486 + // stream at a certain time. The data stream thus carries an accurate internal
  487 + // "clock time". All coding and de- coding processes are controlled by this clock
  488 + // time. To do this, the receiver, i.e. the MPEG decoder, must read out the
  489 + // "clock time", namely the PCR values, and compare them with its own internal
  490 + // system clock, that is to say its own 42 bit counter.
483 int64_t pcr = write_pcr? msg->dts : -1; 491 int64_t pcr = write_pcr? msg->dts : -1;
484 492
485 // TODO: FIXME: finger it why use discontinuity of msg. 493 // TODO: FIXME: finger it why use discontinuity of msg.