mpegtsmux: reset pes_bytes_written when starting to write new PES packet

In case of an unbounded packet (video usually), pes_bytes_written was
no reset.

https://bugzilla.gnome.org/show_bug.cgi?id=748507
This commit is contained in:
Hyunjun Ko 2015-07-14 13:42:54 +09:00 committed by Tim-Philipp Müller
parent ab5aab60a9
commit f9ef150652

View file

@ -316,8 +316,10 @@ tsmux_stream_consume (TsMuxStream * stream, guint len)
/* FIXME: As a hack, for unbounded streams, start a new PES packet for each
* incoming packet we receive. This assumes that incoming data is
* packetised sensibly - ie, every video frame */
if (stream->cur_pes_payload_size == 0)
if (stream->cur_pes_payload_size == 0) {
stream->state = TSMUX_STREAM_STATE_HEADER;
stream->pes_bytes_written = 0;
}
}
}