mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 01:00:37 +00:00
Revert "qtdemux: fill timestamp table completely"
This reverts commit 790b050fc5
.
I forgot we were frozen.
This commit is contained in:
parent
790b050fc5
commit
9f022c8a85
1 changed files with 3 additions and 18 deletions
|
@ -3464,7 +3464,6 @@ qtdemux_parse_samples (GstQTDemux * qtdemux, QtDemuxStream * stream,
|
||||||
done2:
|
done2:
|
||||||
|
|
||||||
n_sample_times = QT_UINT32 (stts_data + 12);
|
n_sample_times = QT_UINT32 (stts_data + 12);
|
||||||
GST_LOG_OBJECT (qtdemux, "%u timestamp blocks", n_sample_times);
|
|
||||||
timestamp = 0;
|
timestamp = 0;
|
||||||
stream->min_duration = 0;
|
stream->min_duration = 0;
|
||||||
time = 0;
|
time = 0;
|
||||||
|
@ -3478,17 +3477,14 @@ qtdemux_parse_samples (GstQTDemux * qtdemux, QtDemuxStream * stream,
|
||||||
stts_data += 4;
|
stts_data += 4;
|
||||||
duration = QT_UINT32 (stts_data);
|
duration = QT_UINT32 (stts_data);
|
||||||
stts_data += 4;
|
stts_data += 4;
|
||||||
GST_LOG_OBJECT (qtdemux, "block %d, %u timestamps, duration %u ", i, n,
|
|
||||||
duration);
|
|
||||||
|
|
||||||
/* take first duration for fps */
|
/* take first duration for fps */
|
||||||
if (G_UNLIKELY (stream->min_duration == 0))
|
if (G_UNLIKELY (stream->min_duration == 0))
|
||||||
stream->min_duration = duration;
|
stream->min_duration = duration;
|
||||||
|
|
||||||
for (j = 0; j < n; j++) {
|
for (j = 0; j < n; j++) {
|
||||||
GST_DEBUG_OBJECT (qtdemux,
|
GST_DEBUG_OBJECT (qtdemux, "sample %d: timestamp %" GST_TIME_FORMAT,
|
||||||
"sample %d: index %d, timestamp %" GST_TIME_FORMAT, index, j,
|
index, GST_TIME_ARGS (timestamp));
|
||||||
GST_TIME_ARGS (timestamp));
|
|
||||||
|
|
||||||
samples[index].timestamp = timestamp;
|
samples[index].timestamp = timestamp;
|
||||||
/* add non-scaled values to avoid rounding errors */
|
/* add non-scaled values to avoid rounding errors */
|
||||||
|
@ -3501,16 +3497,6 @@ qtdemux_parse_samples (GstQTDemux * qtdemux, QtDemuxStream * stream,
|
||||||
goto done3;
|
goto done3;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* fill up empty timestamps with the last timestamp, this can happen when
|
|
||||||
* the last samples do not decoder and so we don't have timestamps for them.
|
|
||||||
* We however look at the last timestamp to estimate the track length so we
|
|
||||||
* need something in here. */
|
|
||||||
for (; index < n_samples; index++) {
|
|
||||||
GST_DEBUG_OBJECT (qtdemux, "fill sample %d: timestamp %" GST_TIME_FORMAT,
|
|
||||||
index, GST_TIME_ARGS (timestamp));
|
|
||||||
samples[index].timestamp = timestamp;
|
|
||||||
samples[index].duration = -1;
|
|
||||||
}
|
|
||||||
done3:
|
done3:
|
||||||
|
|
||||||
/* sample sync, can be NULL */
|
/* sample sync, can be NULL */
|
||||||
|
@ -3797,8 +3783,7 @@ done:
|
||||||
stream->segments[0].media_stop = stream_duration;
|
stream->segments[0].media_stop = stream_duration;
|
||||||
stream->segments[0].rate = 1.0;
|
stream->segments[0].rate = 1.0;
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (qtdemux, "created dummy segment %" GST_TIME_FORMAT,
|
GST_DEBUG_OBJECT (qtdemux, "created dummy segment");
|
||||||
GST_TIME_ARGS (stream_duration));
|
|
||||||
stream->n_segments = 1;
|
stream->n_segments = 1;
|
||||||
}
|
}
|
||||||
GST_DEBUG_OBJECT (qtdemux, "using %d segments", stream->n_segments);
|
GST_DEBUG_OBJECT (qtdemux, "using %d segments", stream->n_segments);
|
||||||
|
|
Loading…
Reference in a new issue