mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-04 22:48:54 +00:00
mpegtsmux: optionally set data_alignment flag in PES header
This commit is contained in:
parent
c76627ec9a
commit
fd92a8b65a
2 changed files with 6 additions and 1 deletions
|
@ -113,6 +113,7 @@ G_BEGIN_DECLS
|
|||
#define TSMUX_PACKET_FLAG_PES_WRITE_PTS_DTS (1 << 10)
|
||||
#define TSMUX_PACKET_FLAG_PES_WRITE_ESCR (1 << 11)
|
||||
#define TSMUX_PACKET_FLAG_PES_EXT_STREAMID (1 << 12)
|
||||
#define TSMUX_PACKET_FLAG_PES_DATA_ALIGNMENT (1 << 13)
|
||||
|
||||
/* PAT interval (1/10th sec) */
|
||||
#define TSMUX_DEFAULT_PAT_INTERVAL (TSMUX_CLOCK_FREQ / 10)
|
||||
|
|
|
@ -578,7 +578,11 @@ tsmux_stream_write_pes_header (TsMuxStream * stream, guint8 * data)
|
|||
guint8 flags = 0;
|
||||
|
||||
/* Not scrambled, original, not-copyrighted, data_alignment not specified */
|
||||
*data++ = 0x81;
|
||||
flags = 0x81;
|
||||
if (stream->pi.flags & TSMUX_PACKET_FLAG_PES_DATA_ALIGNMENT)
|
||||
flags |= 0x4;
|
||||
*data++ = flags;
|
||||
flags = 0;
|
||||
|
||||
/* Flags */
|
||||
if (stream->pi.flags & TSMUX_PACKET_FLAG_PES_WRITE_PTS_DTS)
|
||||
|
|
Loading…
Reference in a new issue