Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
gst-plugins-good
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jan Alexander Steffens
gst-plugins-good
Commits
09904e59
Commit
09904e59
authored
Oct 02, 2018
by
Vivia Nikolaidou
🦆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
qtmux: Allow up to 1% of frame rate for lateness
https://bugzilla.gnome.org/show_bug.cgi?id=797290
parent
ee461fb3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
gst/isomp4/gstqtmux.c
gst/isomp4/gstqtmux.c
+12
-2
No files found.
gst/isomp4/gstqtmux.c
View file @
09904e59
...
...
@@ -3495,7 +3495,7 @@ gst_qt_mux_update_edit_lists (GstQTMux * qtmux)
has_gap
=
(
qtpad
->
first_ts
>
(
qtmux
->
first_ts
+
qtpad
->
dts_adjustment
));
if
(
has_gap
)
{
GstClockTime
diff
,
trak_lateness
;
GstClockTime
diff
,
trak_lateness
,
one_percent_of_frame_duration
=
0
;
diff
=
qtpad
->
first_ts
-
(
qtmux
->
first_ts
+
qtpad
->
dts_adjustment
);
lateness
=
gst_util_uint64_scale_round
(
diff
,
...
...
@@ -3506,7 +3506,17 @@ gst_qt_mux_update_edit_lists (GstQTMux * qtmux)
trak_lateness
=
gst_util_uint64_scale
(
diff
,
atom_trak_get_timescale
(
qtpad
->
trak
),
GST_SECOND
);
if
(
lateness
>
0
&&
trak_lateness
>
0
)
{
/* If the lateness is less than 1% of the (video) frame duration, we
* just allow it. It's usually irrelevantly small anyway, and having
* such a short edit list of -1 might break other cases (e.g. in
* prefill mode it will just error out for no real reason) */
if
(
qtpad
->
expected_sample_duration_n
!=
0
)
{
one_percent_of_frame_duration
=
gst_util_uint64_scale
(
qtpad
->
expected_sample_duration_d
,
GST_SECOND
,
100
*
qtpad
->
expected_sample_duration_n
);
}
if
(
lateness
>
one_percent_of_frame_duration
&&
trak_lateness
>
0
)
{
GST_DEBUG_OBJECT
(
qtmux
,
"Pad %s is a late stream by %"
GST_TIME_FORMAT
,
GST_PAD_NAME
(
qtpad
->
collect
.
pad
),
GST_TIME_ARGS
(
diff
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment