GstFlowReturn ret = GST_FLOW_OK;
MpegPsPadData *best = NULL;
+ gboolean keyunit;
GST_DEBUG_OBJECT (mux, "Pads collected");
G_GINT64_FORMAT, GST_TIME_ARGS (best->cur_ts), pts);
}
+ keyunit = !GST_BUFFER_FLAG_IS_SET (buf, GST_BUFFER_FLAG_DELTA_UNIT);
+
/* give the buffer to libpsmux for processing */
psmux_stream_add_data (best->stream, GST_BUFFER_DATA (buf),
- GST_BUFFER_SIZE (buf), buf, pts, -1);
+ GST_BUFFER_SIZE (buf), buf, pts, -1, keyunit);
+
best->queued_buf = NULL;
/* write the data from libpsmux to stream */
*/
void
psmux_stream_add_data (PsMuxStream * stream, guint8 * data, guint len,
- void *user_data, gint64 pts, gint64 dts)
+ void *user_data, gint64 pts, gint64 dts, gboolean keyunit)
{
PsMuxStreamBuffer *packet;
packet->size = len;
packet->user_data = user_data;
+ packet->keyunit = keyunit;
packet->pts = pts;
packet->dts = dts;
guint8 *data;
guint32 size;
+ gboolean keyunit;
+
/* PTS & DTS associated with the contents of this buffer */
GstClockTime pts;
GstClockTime dts;
/* Add a new buffer to the pool of available bytes. If pts or dts are not -1, they
* indicate the PTS or DTS of the first access unit within this packet */
void psmux_stream_add_data (PsMuxStream *stream, guint8 *data, guint len,
- void *user_data, gint64 pts, gint64 dts);
+ void *user_data, gint64 pts, gint64 dts,
+ gboolean keyunit);
/* total bytes in buffer */
gint psmux_stream_bytes_in_buffer (PsMuxStream *stream);