);
static GstStaticPadTemplate audio_src_template =
-GST_STATIC_PAD_TEMPLATE ("audio_%02d",
+GST_STATIC_PAD_TEMPLATE ("audio_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
GST_STATIC_CAPS_ANY);
static GstStaticPadTemplate video_src_template =
-GST_STATIC_PAD_TEMPLATE ("video_%02d",
+GST_STATIC_PAD_TEMPLATE ("video_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
GST_STATIC_CAPS_ANY);
size_left = audio->size;
/* Create the audio pad */
- name = g_strdup_printf ("audio_%02d", demux->num_audio_streams);
+ name = g_strdup_printf ("audio_%u", demux->num_audio_streams);
src_pad = gst_pad_new_from_static_template (&audio_src_template, name);
g_free (name);
gint size_left = video->size - 40;
/* Create the video pad */
- name = g_strdup_printf ("video_%02d", demux->num_video_streams);
+ name = g_strdup_printf ("video_%u", demux->num_video_streams);
src_pad = gst_pad_new_from_static_template (&video_src_template, name);
g_free (name);
flags = gst_asf_demux_get_uint16 (&data, &size);
stream_id = flags & 0x7f;
- is_encrypted = !!((flags & 0x8000) << 15);
+ is_encrypted = ! !((flags & 0x8000) << 15);
unknown = gst_asf_demux_get_uint32 (&data, &size);
GST_DEBUG_OBJECT (demux, "Found stream %u, time_offset=%" GST_TIME_FORMAT,
max_pktsize = gst_asf_demux_get_uint32 (&data, &size);
min_bitrate = gst_asf_demux_get_uint32 (&data, &size);
- demux->broadcast = !!(flags & 0x01);
- demux->seekable = !!(flags & 0x02);
+ demux->broadcast = ! !(flags & 0x01);
+ demux->seekable = ! !(flags & 0x02);
GST_DEBUG_OBJECT (demux, "min_pktsize = %u", min_pktsize);
GST_DEBUG_OBJECT (demux, "flags::broadcast = %d", demux->broadcast);
VIDEO_CAPS);
static GstStaticPadTemplate audio_template =
-GST_STATIC_PAD_TEMPLATE ("dvd_audio_%02d",
+GST_STATIC_PAD_TEMPLATE ("dvd_audio_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
AUDIO_CAPS);
AUDIO_CAPS);
static GstStaticPadTemplate subpicture_template =
-GST_STATIC_PAD_TEMPLATE ("subpicture_%d",
+GST_STATIC_PAD_TEMPLATE ("subpicture_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
SUBPICTURE_CAPS);
str = (GstMPEGStream *) lpcm_str;
}
- name = g_strdup_printf ("audio_%02d", stream_nr);
+ name = g_strdup_printf ("audio_%u", stream_nr);
DEMUX_CLASS (dvd_demux)->init_stream (mpeg_demux, type, str, stream_nr,
name, DEMUX_CLASS (dvd_demux)->audio_template);
/* update caps */
);
static GstStaticPadTemplate video_template =
-GST_STATIC_PAD_TEMPLATE ("video_%02d",
+GST_STATIC_PAD_TEMPLATE ("video_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
GST_STATIC_CAPS ("video/mpeg, "
);
static GstStaticPadTemplate audio_template =
-GST_STATIC_PAD_TEMPLATE ("audio_%02d",
+GST_STATIC_PAD_TEMPLATE ("audio_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
GST_STATIC_CAPS ("audio/mpeg, " "mpegversion = (int) 1"
);
static GstStaticPadTemplate private_template =
-GST_STATIC_PAD_TEMPLATE ("private_%d",
+GST_STATIC_PAD_TEMPLATE ("private_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
GST_STATIC_CAPS_ANY);
video_str = g_new0 (GstMPEGVideoStream, 1);
str = (GstMPEGStream *) video_str;
- name = g_strdup_printf ("video_%02d", stream_nr);
+ name = g_strdup_printf ("video_%u", stream_nr);
CLASS (mpeg_demux)->init_stream (mpeg_demux, type, str, stream_nr, name,
CLASS (mpeg_demux)->video_template);
g_free (name);
if (str == NULL) {
str = g_new0 (GstMPEGStream, 1);
- name = g_strdup_printf ("audio_%02d", stream_nr);
+ name = g_strdup_printf ("audio_%u", stream_nr);
CLASS (mpeg_demux)->init_stream (mpeg_demux, type, str, stream_nr, name,
CLASS (mpeg_demux)->audio_template);
g_free (name);
str = mpeg_demux->private_stream[stream_nr];
if (str == NULL) {
- name = g_strdup_printf ("private_%d", stream_nr + 1);
+ name = g_strdup_printf ("private_%u", stream_nr + 1);
str = g_new0 (GstMPEGStream, 1);
CLASS (mpeg_demux)->init_stream (mpeg_demux, type, str, stream_nr, name,
CLASS (mpeg_demux)->private_template);
);
static GstStaticPadTemplate gst_rmdemux_videosrc_template =
-GST_STATIC_PAD_TEMPLATE ("video_%02d",
+GST_STATIC_PAD_TEMPLATE ("video_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
GST_STATIC_CAPS_ANY);
static GstStaticPadTemplate gst_rmdemux_audiosrc_template =
-GST_STATIC_PAD_TEMPLATE ("audio_%02d",
+GST_STATIC_PAD_TEMPLATE ("audio_%u",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
GST_STATIC_CAPS_ANY);
int version = 0;
if (stream->subtype == GST_RMDEMUX_STREAM_VIDEO) {
- char *name = g_strdup_printf ("video_%02d", rmdemux->n_video_streams);
+ char *name = g_strdup_printf ("video_%u", rmdemux->n_video_streams);
stream->pad =
gst_pad_new_from_static_template (&gst_rmdemux_videosrc_template, name);
rmdemux->n_video_streams++;
} else if (stream->subtype == GST_RMDEMUX_STREAM_AUDIO) {
- char *name = g_strdup_printf ("audio_%02d", rmdemux->n_audio_streams);
+ char *name = g_strdup_printf ("audio_%u", rmdemux->n_audio_streams);
stream->pad =
gst_pad_new_from_static_template (&gst_rmdemux_audiosrc_template, name);
GstPad *sinkpad;
GSList *streams;
- int n_video_streams;
- int n_audio_streams;
+ guint n_video_streams;
+ guint n_audio_streams;
GstAdapter *adapter;
gboolean have_pads;