}
if (dashstream->moof_sync_samples
- && GST_ADAPTIVE_DEMUX (dashdemux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) {
+ && GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (dashdemux)) {
GstDashStreamSyncSample *sync_sample =
&g_array_index (dashstream->moof_sync_samples, GstDashStreamSyncSample,
dashstream->current_sync_sample);
{
GstDashDemuxStream *dashstream = (GstDashDemuxStream *) stream;
- if (dashstream->moof_sync_samples
- && GST_ADAPTIVE_DEMUX (stream->demux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) {
+ if (dashstream->moof_sync_samples &&
+ GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (stream->demux)) {
if (stream->demux->segment.rate > 0.0) {
if (dashstream->current_sync_sample + 1 <
dashstream->moof_sync_samples->len)
GstDashDemuxStream *dashstream = (GstDashDemuxStream *) stream;
gboolean fragment_finished = FALSE;
- if (dashstream->moof_sync_samples
- && GST_ADAPTIVE_DEMUX (stream->demux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) {
+ if (dashstream->moof_sync_samples &&
+ GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (stream->demux)) {
if (stream->demux->segment.rate > 0.0) {
dashstream->current_sync_sample++;
if (dashstream->current_sync_sample >= dashstream->moof_sync_samples->len) {
GstDashDemux *dashdemux = GST_DASH_DEMUX_CAST (stream->demux);
GstDashDemuxStream *dashstream = (GstDashDemuxStream *) stream;
- if (dashstream->moof_sync_samples
- && GST_ADAPTIVE_DEMUX (dashdemux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) {
+ if (dashstream->moof_sync_samples &&
+ GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (dashdemux)) {
if (gst_dash_demux_stream_has_next_sync_sample (stream))
return TRUE;
}
GST_DEBUG_OBJECT (stream->pad, "Advance fragment");
/* If downloading only keyframes, switch to the next one or fall through */
- if (dashstream->moof_sync_samples
- && GST_ADAPTIVE_DEMUX (dashdemux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) {
+ if (dashstream->moof_sync_samples &&
+ GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (dashdemux)) {
if (gst_dash_demux_stream_advance_sync_sample (stream))
return GST_FLOW_OK;
}
}
/* get representation index with current max_bandwidth */
- if ((base_demux->segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) ||
+ if (GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (base_demux) ||
ABS (base_demux->segment.rate) <= 1.0) {
new_index =
gst_mpdparser_get_rep_idx_with_max_bandwidth (rep_list, bitrate,
* buffer. We need offsets to be consistent between moof and mdat
*/
if (dashstream->is_isobmff && dashdemux->allow_trickmode_key_units
- && (demux->segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS)
+ && GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (demux)
&& dashstream->active_stream->mimeType == GST_STREAM_VIDEO)
stream->discont = TRUE;
* buffer. We need offsets to be consistent between moof and mdat
*/
if (dashstream->is_isobmff && dashdemux->allow_trickmode_key_units
- && (demux->segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS)
+ && GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (demux)
&& dashstream->active_stream->mimeType == GST_STREAM_VIDEO)
stream->discont = TRUE;
/* Only handle fragment advancing specifically for SIDX if we're not
* in key unit mode */
if (!(dashstream->moof_sync_samples
- && GST_ADAPTIVE_DEMUX (dashdemux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS)
+ && GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (dashdemux))
&& gst_mpd_client_has_isoff_ondemand_profile (dashdemux->client)
&& dashstream->sidx_parser.status == GST_ISOFF_SIDX_PARSER_FINISHED) {
/* fragment is advanced on data_received when byte limits are reached */
* random guess for the moof size
*/
if (dashstream->is_isobmff
- && (GST_ADAPTIVE_DEMUX (stream->demux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS)
+ && GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (stream->demux)
&& dashstream->active_stream->mimeType == GST_STREAM_VIDEO
&& !stream->downloading_header && !stream->downloading_index
&& dashdemux->allow_trickmode_key_units) {
* trickmodes while doing chunked downloading. In that case
* just download from here to the end now */
if (dashstream->moof
- && (GST_ADAPTIVE_DEMUX (stream->demux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS))
+ && GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (stream->demux))
stream->fragment.chunk_size = -1;
else
stream->fragment.chunk_size = 0;
* reuse the data if the sync sample follows the moof */
if (dash_stream->active_stream->mimeType == GST_STREAM_VIDEO
&& gst_dash_demux_find_sync_samples (demux, stream) &&
- GST_ADAPTIVE_DEMUX (stream->demux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) {
+ GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (stream->demux)) {
if (dash_stream->first_sync_sample_after_moof) {
/* If we're here, don't throw away data but collect sync
/* We're actually running in key-units trick mode */
if (dash_stream->active_stream->mimeType == GST_STREAM_VIDEO
&& dash_stream->moof_sync_samples
- && GST_ADAPTIVE_DEMUX (stream->demux)->
- segment.flags & GST_SEGMENT_FLAG_TRICKMODE_KEY_UNITS) {
-
+ && GST_ADAPTIVE_DEMUX_IN_TRICKMODE_KEY_UNITS (stream->demux)) {
if (dash_stream->current_sync_sample == -1) {
/* We're doing chunked downloading and wait for finishing the current
* chunk so we can jump to the first keyframe */