mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 03:56:16 +00:00
dashdemux: run gst-indent
Lots of indentation issues making it very annoying to commit because of the indent hook. Fix this for once.
This commit is contained in:
parent
08636f3bab
commit
1d2de4a034
2 changed files with 35 additions and 33 deletions
|
@ -239,7 +239,8 @@ static GstPad *gst_dash_demux_create_pad (GstDashDemux * demux);
|
||||||
#define gst_dash_demux_parent_class parent_class
|
#define gst_dash_demux_parent_class parent_class
|
||||||
G_DEFINE_TYPE_WITH_CODE (GstDashDemux, gst_dash_demux, GST_TYPE_ELEMENT,
|
G_DEFINE_TYPE_WITH_CODE (GstDashDemux, gst_dash_demux, GST_TYPE_ELEMENT,
|
||||||
GST_DEBUG_CATEGORY_INIT (gst_dash_demux_debug, "dashdemux", 0,
|
GST_DEBUG_CATEGORY_INIT (gst_dash_demux_debug, "dashdemux", 0,
|
||||||
"dashdemux element"););
|
"dashdemux element");
|
||||||
|
);
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gst_dash_demux_dispose (GObject * obj)
|
gst_dash_demux_dispose (GObject * obj)
|
||||||
|
@ -1210,7 +1211,8 @@ gst_dash_demux_stream_loop (GstDashDemux * demux)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
GST_DEBUG_OBJECT (demux, "Non buffers have preference %" GST_PTR_FORMAT, item->object);
|
GST_DEBUG_OBJECT (demux, "Non buffers have preference %" GST_PTR_FORMAT,
|
||||||
|
item->object);
|
||||||
selected_stream = stream;
|
selected_stream = stream;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -2230,9 +2232,9 @@ gst_dash_demux_get_next_fragment (GstDashDemux * demux,
|
||||||
brate = (size_buffer * 8) / ((double) diff / GST_SECOND);
|
brate = (size_buffer * 8) / ((double) diff / GST_SECOND);
|
||||||
#endif
|
#endif
|
||||||
GST_INFO_OBJECT (demux,
|
GST_INFO_OBJECT (demux,
|
||||||
"Stream: %d Download rate = %" G_GUINT64_FORMAT " Kbits/s (%" G_GUINT64_FORMAT
|
"Stream: %d Download rate = %" G_GUINT64_FORMAT " Kbits/s (%"
|
||||||
" Ko in %.2f s)", selected_stream->index,
|
G_GUINT64_FORMAT " Ko in %.2f s)", selected_stream->index, brate / 1000,
|
||||||
brate / 1000, size_buffer / 1024, ((double) diff / GST_SECOND));
|
size_buffer / 1024, ((double) diff / GST_SECOND));
|
||||||
}
|
}
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -126,8 +126,8 @@ static GstSegmentURLNode *gst_mpdparser_clone_segment_url (GstSegmentURLNode *
|
||||||
seg_url);
|
seg_url);
|
||||||
static gchar *gst_mpdparser_get_mediaURL (GstActiveStream * stream,
|
static gchar *gst_mpdparser_get_mediaURL (GstActiveStream * stream,
|
||||||
GstSegmentURLNode * segmentURL);
|
GstSegmentURLNode * segmentURL);
|
||||||
static const gchar *gst_mpdparser_get_initializationURL (
|
static const gchar *gst_mpdparser_get_initializationURL (GstActiveStream *
|
||||||
GstActiveStream * stream, GstURLType * InitializationURL);
|
stream, GstURLType * InitializationURL);
|
||||||
static gchar *gst_mpdparser_build_URL_from_template (const gchar * url_template,
|
static gchar *gst_mpdparser_build_URL_from_template (const gchar * url_template,
|
||||||
const gchar * id, guint number, guint bandwidth, guint64 time);
|
const gchar * id, guint number, guint bandwidth, guint64 time);
|
||||||
static gboolean gst_mpd_client_add_media_segment (GstActiveStream * stream,
|
static gboolean gst_mpd_client_add_media_segment (GstActiveStream * stream,
|
||||||
|
@ -160,8 +160,7 @@ static GstSegmentListNode *gst_mpdparser_get_segment_list (GstPeriodNode *
|
||||||
static guint gst_mpd_client_get_segments_counts (GstActiveStream * stream);
|
static guint gst_mpd_client_get_segments_counts (GstActiveStream * stream);
|
||||||
|
|
||||||
/* Memory management */
|
/* Memory management */
|
||||||
static GstSegmentTimelineNode *
|
static GstSegmentTimelineNode *gst_mpdparser_segment_timeline_node_new (void);
|
||||||
gst_mpdparser_segment_timeline_node_new (void);
|
|
||||||
static void gst_mpdparser_free_mpd_node (GstMPDNode * mpd_node);
|
static void gst_mpdparser_free_mpd_node (GstMPDNode * mpd_node);
|
||||||
static void gst_mpdparser_free_prog_info_node (GstProgramInformationNode *
|
static void gst_mpdparser_free_prog_info_node (GstProgramInformationNode *
|
||||||
prog_info_node);
|
prog_info_node);
|
||||||
|
@ -1280,12 +1279,12 @@ gst_mpdparser_clone_segment_timeline (GstSegmentTimelineNode * pointer)
|
||||||
clone = gst_mpdparser_segment_timeline_node_new ();
|
clone = gst_mpdparser_segment_timeline_node_new ();
|
||||||
if (clone) {
|
if (clone) {
|
||||||
GList *list;
|
GList *list;
|
||||||
for (list = g_queue_peek_head_link (&pointer->S); list; list = g_list_next (list)) {
|
for (list = g_queue_peek_head_link (&pointer->S); list;
|
||||||
|
list = g_list_next (list)) {
|
||||||
GstSNode *s_node;
|
GstSNode *s_node;
|
||||||
s_node = (GstSNode *) list->data;
|
s_node = (GstSNode *) list->data;
|
||||||
if (s_node) {
|
if (s_node) {
|
||||||
g_queue_push_tail (&clone->S,
|
g_queue_push_tail (&clone->S, gst_mpdparser_clone_s_node (s_node));
|
||||||
gst_mpdparser_clone_s_node (s_node));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
@ -2021,14 +2020,14 @@ gst_mpdparser_get_segment_base (GstPeriodNode * Period,
|
||||||
if (Representation && Representation->SegmentList
|
if (Representation && Representation->SegmentList
|
||||||
&& Representation->SegmentList->MultSegBaseType
|
&& Representation->SegmentList->MultSegBaseType
|
||||||
&& Representation->SegmentList->MultSegBaseType->SegBaseType
|
&& Representation->SegmentList->MultSegBaseType->SegBaseType
|
||||||
&& Representation->SegmentList->MultSegBaseType->SegBaseType->
|
&& Representation->SegmentList->MultSegBaseType->
|
||||||
Initialization) {
|
SegBaseType->Initialization) {
|
||||||
SegmentBase = Representation->SegmentList->MultSegBaseType->SegBaseType;
|
SegmentBase = Representation->SegmentList->MultSegBaseType->SegBaseType;
|
||||||
} else if (AdaptationSet && AdaptationSet->SegmentList
|
} else if (AdaptationSet && AdaptationSet->SegmentList
|
||||||
&& AdaptationSet->SegmentList->MultSegBaseType
|
&& AdaptationSet->SegmentList->MultSegBaseType
|
||||||
&& AdaptationSet->SegmentList->MultSegBaseType->SegBaseType
|
&& AdaptationSet->SegmentList->MultSegBaseType->SegBaseType
|
||||||
&& AdaptationSet->SegmentList->MultSegBaseType->SegBaseType->
|
&& AdaptationSet->SegmentList->MultSegBaseType->
|
||||||
Initialization) {
|
SegBaseType->Initialization) {
|
||||||
SegmentBase = AdaptationSet->SegmentList->MultSegBaseType->SegBaseType;
|
SegmentBase = AdaptationSet->SegmentList->MultSegBaseType->SegBaseType;
|
||||||
} else if (Period && Period->SegmentList
|
} else if (Period && Period->SegmentList
|
||||||
&& Period->SegmentList->MultSegBaseType
|
&& Period->SegmentList->MultSegBaseType
|
||||||
|
@ -2357,8 +2356,7 @@ static void
|
||||||
gst_mpdparser_free_segment_timeline_node (GstSegmentTimelineNode * seg_timeline)
|
gst_mpdparser_free_segment_timeline_node (GstSegmentTimelineNode * seg_timeline)
|
||||||
{
|
{
|
||||||
if (seg_timeline) {
|
if (seg_timeline) {
|
||||||
g_queue_foreach (&seg_timeline->S,
|
g_queue_foreach (&seg_timeline->S, (GFunc) gst_mpdparser_free_s_node, NULL);
|
||||||
(GFunc) gst_mpdparser_free_s_node, NULL);
|
|
||||||
g_queue_clear (&seg_timeline->S);
|
g_queue_clear (&seg_timeline->S);
|
||||||
g_slice_free (GstSegmentTimelineNode, seg_timeline);
|
g_slice_free (GstSegmentTimelineNode, seg_timeline);
|
||||||
}
|
}
|
||||||
|
@ -2497,7 +2495,8 @@ gst_mpdparser_init_active_stream_segments (GstActiveStream * stream)
|
||||||
{
|
{
|
||||||
g_assert (stream->segments == NULL);
|
g_assert (stream->segments == NULL);
|
||||||
stream->segments = g_ptr_array_new ();
|
stream->segments = g_ptr_array_new ();
|
||||||
g_ptr_array_set_free_func (stream->segments, (GDestroyNotify) gst_mpdparser_free_media_segment);
|
g_ptr_array_set_free_func (stream->segments,
|
||||||
|
(GDestroyNotify) gst_mpdparser_free_media_segment);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -2924,8 +2923,8 @@ gst_mpdparser_get_chunk_by_index (GstMpdClient * client, guint indexStream,
|
||||||
segment->duration = list_segment->duration;
|
segment->duration = list_segment->duration;
|
||||||
} else {
|
} else {
|
||||||
GstClockTime duration;
|
GstClockTime duration;
|
||||||
g_return_val_if_fail (stream->cur_seg_template->MultSegBaseType->
|
g_return_val_if_fail (stream->cur_seg_template->
|
||||||
SegmentTimeline == NULL, FALSE);
|
MultSegBaseType->SegmentTimeline == NULL, FALSE);
|
||||||
/* segment template generator */
|
/* segment template generator */
|
||||||
duration = gst_mpd_client_get_segment_duration (client, stream);
|
duration = gst_mpd_client_get_segment_duration (client, stream);
|
||||||
if (!GST_CLOCK_TIME_IS_VALID (duration))
|
if (!GST_CLOCK_TIME_IS_VALID (duration))
|
||||||
|
@ -3053,7 +3052,8 @@ gst_mpd_client_setup_representation (GstMpdClient * client,
|
||||||
GList *list;
|
GList *list;
|
||||||
|
|
||||||
timeline = stream->cur_segment_list->MultSegBaseType->SegmentTimeline;
|
timeline = stream->cur_segment_list->MultSegBaseType->SegmentTimeline;
|
||||||
for (list = g_queue_peek_head_link (&timeline->S); list; list = g_list_next (list)) {
|
for (list = g_queue_peek_head_link (&timeline->S); list;
|
||||||
|
list = g_list_next (list)) {
|
||||||
guint j, timescale;
|
guint j, timescale;
|
||||||
|
|
||||||
S = (GstSNode *) list->data;
|
S = (GstSNode *) list->data;
|
||||||
|
@ -3130,7 +3130,8 @@ gst_mpd_client_setup_representation (GstMpdClient * client,
|
||||||
|
|
||||||
timeline = stream->cur_seg_template->MultSegBaseType->SegmentTimeline;
|
timeline = stream->cur_seg_template->MultSegBaseType->SegmentTimeline;
|
||||||
gst_mpdparser_init_active_stream_segments (stream);
|
gst_mpdparser_init_active_stream_segments (stream);
|
||||||
for (list = g_queue_peek_head_link (&timeline->S); list; list = g_list_next (list)) {
|
for (list = g_queue_peek_head_link (&timeline->S); list;
|
||||||
|
list = g_list_next (list)) {
|
||||||
guint j, timescale;
|
guint j, timescale;
|
||||||
|
|
||||||
S = (GstSNode *) list->data;
|
S = (GstSNode *) list->data;
|
||||||
|
@ -3411,8 +3412,8 @@ gst_mpd_client_stream_seek (GstMpdClient * client, GstActiveStream * stream,
|
||||||
} else {
|
} else {
|
||||||
GstClockTime duration =
|
GstClockTime duration =
|
||||||
gst_mpd_client_get_segment_duration (client, stream);
|
gst_mpd_client_get_segment_duration (client, stream);
|
||||||
g_return_val_if_fail (stream->cur_seg_template->MultSegBaseType->
|
g_return_val_if_fail (stream->cur_seg_template->
|
||||||
SegmentTimeline == NULL, FALSE);
|
MultSegBaseType->SegmentTimeline == NULL, FALSE);
|
||||||
if (!GST_CLOCK_TIME_IS_VALID (duration)) {
|
if (!GST_CLOCK_TIME_IS_VALID (duration)) {
|
||||||
GST_MPD_CLIENT_UNLOCK (client);
|
GST_MPD_CLIENT_UNLOCK (client);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
@ -3606,10 +3607,9 @@ gst_mpd_client_get_next_fragment (GstMpdClient * client,
|
||||||
stream->cur_representation->bandwidth, currentChunk.start);
|
stream->cur_representation->bandwidth, currentChunk.start);
|
||||||
if (stream->cur_seg_template->index) {
|
if (stream->cur_seg_template->index) {
|
||||||
indexURL =
|
indexURL =
|
||||||
gst_mpdparser_build_URL_from_template (stream->
|
gst_mpdparser_build_URL_from_template (stream->cur_seg_template->
|
||||||
cur_seg_template->index, stream->cur_representation->id,
|
index, stream->cur_representation->id, currentChunk.number,
|
||||||
currentChunk.number, stream->cur_representation->bandwidth,
|
stream->cur_representation->bandwidth, currentChunk.start);
|
||||||
currentChunk.start);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
GST_DEBUG ("mediaURL = %s", mediaURL);
|
GST_DEBUG ("mediaURL = %s", mediaURL);
|
||||||
|
@ -3801,8 +3801,8 @@ gst_mpd_client_get_next_fragment_duration (GstMpdClient * client,
|
||||||
} else {
|
} else {
|
||||||
GstClockTime duration =
|
GstClockTime duration =
|
||||||
gst_mpd_client_get_segment_duration (client, stream);
|
gst_mpd_client_get_segment_duration (client, stream);
|
||||||
g_return_val_if_fail (stream->cur_seg_template->MultSegBaseType->
|
g_return_val_if_fail (stream->cur_seg_template->
|
||||||
SegmentTimeline == NULL, 0);
|
MultSegBaseType->SegmentTimeline == NULL, 0);
|
||||||
|
|
||||||
if (GST_CLOCK_TIME_IS_VALID (duration))
|
if (GST_CLOCK_TIME_IS_VALID (duration))
|
||||||
return duration;
|
return duration;
|
||||||
|
@ -3961,8 +3961,8 @@ gst_mpd_client_get_segments_counts (GstActiveStream * stream)
|
||||||
|
|
||||||
if (stream->segments)
|
if (stream->segments)
|
||||||
return stream->segments->len;
|
return stream->segments->len;
|
||||||
g_return_val_if_fail (stream->cur_seg_template->MultSegBaseType->
|
g_return_val_if_fail (stream->cur_seg_template->
|
||||||
SegmentTimeline == NULL, 0);
|
MultSegBaseType->SegmentTimeline == NULL, 0);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue