mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-26 19:01:44 +02:00
only write dts if they differ from pts, according to specs
Originally committed as revision 16605 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
46911c7ab8
commit
5541759f6f
@ -576,7 +576,7 @@ static void mpegts_write_pes(AVFormatContext *s, AVStream *st,
|
||||
header_len += 5;
|
||||
flags |= 0x80;
|
||||
}
|
||||
if (dts != AV_NOPTS_VALUE) {
|
||||
if (dts != AV_NOPTS_VALUE && dts != pts) {
|
||||
header_len += 5;
|
||||
flags |= 0x40;
|
||||
}
|
||||
@ -609,7 +609,7 @@ static void mpegts_write_pes(AVFormatContext *s, AVStream *st,
|
||||
write_pts(q, flags >> 6, pts);
|
||||
q += 5;
|
||||
}
|
||||
if (dts != AV_NOPTS_VALUE) {
|
||||
if (dts != AV_NOPTS_VALUE && dts != pts) {
|
||||
write_pts(q, 1, dts);
|
||||
q += 5;
|
||||
}
|
||||
|
@ -9,8 +9,8 @@ c351132527ccb1e8cab06cc0822fde23 *./tests/data/b-libav.rm
|
||||
bdb7484c68db722f66ba1630cf79844c *./tests/data/b-libav.mpg
|
||||
378880 ./tests/data/b-libav.mpg
|
||||
./tests/data/b-libav.mpg CRC=0x2b71a386
|
||||
9fd96456cbf2a550da816e563316d92f *./tests/data/b-libav.ts
|
||||
471692 ./tests/data/b-libav.ts
|
||||
676a06e0f0f6639f5199efd52fec9ca9 *./tests/data/b-libav.ts
|
||||
471316 ./tests/data/b-libav.ts
|
||||
./tests/data/b-libav.ts CRC=0xcc4948e1
|
||||
1b28a16652bb8ac528b33f7478ca18b6 *./tests/data/b-libav.swf
|
||||
335771 ./tests/data/b-libav.swf
|
||||
|
Loading…
Reference in New Issue
Block a user