From: <sl...@ke...> - 2009-08-31 07:28:10
|
Module: gst-plugins-bad Branch: master Commit: 451275714ca598f3fcb70f23f13b74b160ce875d URL: http://cgit.freedesktop.org/gstreamer/gst-plugins-bad/commit/?id=451275714ca598f3fcb70f23f13b74b160ce875d Author: Lin YANG <oxc...@gm...> Date: Sat Jul 11 19:13:23 2009 +0800 mpegtsmux: MpetTsPadData: add prog_id and ref to its program --- gst/mpegtsmux/mpegtsmux.c | 2 ++ gst/mpegtsmux/mpegtsmux.h | 7 +++++++ 2 files changed, 9 insertions(+), 0 deletions(-) diff --git a/gst/mpegtsmux/mpegtsmux.c b/gst/mpegtsmux/mpegtsmux.c index 84efb6a..1e595c0 100644 --- a/gst/mpegtsmux/mpegtsmux.c +++ b/gst/mpegtsmux/mpegtsmux.c @@ -671,6 +671,8 @@ mpegtsmux_request_new_pad (GstElement * element, pad_data->last_ts = GST_CLOCK_TIME_NONE; pad_data->codec_data = NULL; pad_data->prepare_func = NULL; + pad_data->prog_id = -1; + pad_data->prog = NULL; if (G_UNLIKELY (!gst_element_add_pad (element, pad))) goto could_not_add; diff --git a/gst/mpegtsmux/mpegtsmux.h b/gst/mpegtsmux/mpegtsmux.h index 9f1a808..a519393 100644 --- a/gst/mpegtsmux/mpegtsmux.h +++ b/gst/mpegtsmux/mpegtsmux.h @@ -142,6 +142,9 @@ struct MpegTsPadData { MpegTsPadDataPrepareFunction prepare_func; /* Handler to prepare input data */ gboolean eos; + + gint prog_id; /* The program id to which it is attached to (not program pid) */ + TsMuxProgram *prog; /* The program to which this stream belongs to */ }; GType mpegtsmux_get_type (void); @@ -159,6 +162,10 @@ GType mpegtsmux_get_type (void); #define STANDARD_TIME_CLOCK 27000000 /*33 bits as 1 ie 0x1ffffffff*/ #define TWO_POW_33_MINUS1 ((0xffffffff * 2) - 1) + +#define MAX_PROG_NUMBER 32 +#define DEFAULT_PROG_ID 0 + G_END_DECLS #endif |