mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2025-09-02 17:53:48 +00:00
fmp4mux: Use earliest PTS for the base media decode time (tfdt)
While this is supposed to be a decode time, this doesn't really match the description in the specification. It starts at 0 and increases by the duration of each fragment, i.e. is the sum of all previous sample durations. Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2223>
This commit is contained in:
parent
3012dac758
commit
6df4adac31
1 changed files with 1 additions and 11 deletions
|
@ -2452,8 +2452,6 @@ impl FMP4Mux {
|
||||||
Option<gst::ClockTime>,
|
Option<gst::ClockTime>,
|
||||||
// End DTS
|
// End DTS
|
||||||
Option<gst::ClockTime>,
|
Option<gst::ClockTime>,
|
||||||
// Start time (either matches start_dts if required or earliest-pts)
|
|
||||||
gst::ClockTime,
|
|
||||||
// Start NTP time (either matches start_dts if required or earliest_pts)
|
// Start NTP time (either matches start_dts if required or earliest_pts)
|
||||||
Option<gst::ClockTime>,
|
Option<gst::ClockTime>,
|
||||||
)>,
|
)>,
|
||||||
|
@ -2585,12 +2583,6 @@ impl FMP4Mux {
|
||||||
let start_dts = start_dts;
|
let start_dts = start_dts;
|
||||||
let start_dts_position = start_dts_position;
|
let start_dts_position = start_dts_position;
|
||||||
|
|
||||||
let start_time = if !stream.delta_frames.requires_dts() {
|
|
||||||
earliest_pts
|
|
||||||
} else {
|
|
||||||
start_dts.unwrap()
|
|
||||||
};
|
|
||||||
|
|
||||||
Ok(Some((
|
Ok(Some((
|
||||||
buffers,
|
buffers,
|
||||||
earliest_pts,
|
earliest_pts,
|
||||||
|
@ -2599,7 +2591,6 @@ impl FMP4Mux {
|
||||||
start_dts,
|
start_dts,
|
||||||
start_dts_position,
|
start_dts_position,
|
||||||
end_dts,
|
end_dts,
|
||||||
start_time,
|
|
||||||
start_ntp_time,
|
start_ntp_time,
|
||||||
)))
|
)))
|
||||||
}
|
}
|
||||||
|
@ -2839,7 +2830,6 @@ impl FMP4Mux {
|
||||||
start_dts,
|
start_dts,
|
||||||
start_dts_position,
|
start_dts_position,
|
||||||
_end_dts,
|
_end_dts,
|
||||||
start_time,
|
|
||||||
start_ntp_time,
|
start_ntp_time,
|
||||||
) = match buffers {
|
) = match buffers {
|
||||||
Some(res) => res,
|
Some(res) => res,
|
||||||
|
@ -2892,7 +2882,7 @@ impl FMP4Mux {
|
||||||
drained_streams.push((
|
drained_streams.push((
|
||||||
super::FragmentHeaderStream {
|
super::FragmentHeaderStream {
|
||||||
caps: stream.caps.clone(),
|
caps: stream.caps.clone(),
|
||||||
start_time: Some(start_time),
|
start_time: Some(earliest_pts),
|
||||||
start_ntp_time,
|
start_ntp_time,
|
||||||
delta_frames: stream.delta_frames,
|
delta_frames: stream.delta_frames,
|
||||||
trak_timescale,
|
trak_timescale,
|
||||||
|
|
Loading…
Reference in a new issue