data: Add a Backward and Forward seeking scenario
This commit is contained in:
parent
0d819e51cf
commit
ff3e435e94
@ -1,3 +1,5 @@
|
|||||||
scenariosdir=${datadir}/gstreamer-$(GST_API_VERSION)/qa-scenario
|
scenariosdir=${datadir}/gstreamer-$(GST_API_VERSION)/qa-scenario
|
||||||
scenarios_DATA = simple_seeks.scenario pause_resume.scenario
|
scenarios_DATA = simple_seeks.scenario pause_resume.scenario \
|
||||||
EXTRA_DIST = simple_seeks.scenario pause_resume.scenario
|
seek_forward_backward.scenario
|
||||||
|
EXTRA_DIST = simple_seeks.scenario pause_resume.scenario \
|
||||||
|
seek_forward_backward.scenario
|
||||||
|
85
validate/data/seek_forward_backward.scenario
Normal file
85
validate/data/seek_forward_backward.scenario
Normal file
@ -0,0 +1,85 @@
|
|||||||
|
<scenario name="Backward and forward seeking">
|
||||||
|
<actions>
|
||||||
|
<seek name='Forward seek with stop time'
|
||||||
|
playback_time="0"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="5.0"
|
||||||
|
stop_type="set"
|
||||||
|
stop="-1.0" />
|
||||||
|
|
||||||
|
<seek name='Backward seek'
|
||||||
|
playback_time="10"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="0"
|
||||||
|
stop_type="set"
|
||||||
|
stop="-1.0" />
|
||||||
|
|
||||||
|
<seek name='Backward seek'
|
||||||
|
playback_time="5"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="25"
|
||||||
|
stop_type="set"
|
||||||
|
stop="-1" />
|
||||||
|
|
||||||
|
<seek name='Backward seek'
|
||||||
|
playback_time="30"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="0.0"
|
||||||
|
stop_type="set"
|
||||||
|
stop="-1.0" />
|
||||||
|
|
||||||
|
<seek name='Forward seek'
|
||||||
|
playback_time="5.0"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="15.0"
|
||||||
|
stop_type="set"
|
||||||
|
stop="-1.0" />
|
||||||
|
|
||||||
|
<seek name='Forward seek'
|
||||||
|
playback_time="20.0"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="35"
|
||||||
|
stop_type="set"
|
||||||
|
stop="-1.0" />
|
||||||
|
|
||||||
|
<seek name='Backward seek'
|
||||||
|
playback_time="40"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="25"
|
||||||
|
stop_type="set"
|
||||||
|
stop="-1.0" />
|
||||||
|
|
||||||
|
<seek name='Last backward seek with stop time'
|
||||||
|
playback_time="3.0"
|
||||||
|
format="time"
|
||||||
|
rate="1.0"
|
||||||
|
flags="accurate+flush"
|
||||||
|
start_type="set"
|
||||||
|
start="5.0"
|
||||||
|
stop_type="set"
|
||||||
|
stop="10.0" />
|
||||||
|
|
||||||
|
</actions>
|
||||||
|
</scenario>
|
||||||
|
|
@ -417,6 +417,7 @@ _execute_action (GstValidateScenario * scenario, ScenarioAction * act)
|
|||||||
SCENARIO_ACTION (seek)->action_number, GST_TIME_ARGS (seek->start),
|
SCENARIO_ACTION (seek)->action_number, GST_TIME_ARGS (seek->start),
|
||||||
GST_TIME_ARGS (seek->stop), seek->rate);
|
GST_TIME_ARGS (seek->stop), seek->rate);
|
||||||
|
|
||||||
|
priv->seeked_position = (seek->rate > 0) ? seek->start : seek->stop;
|
||||||
if (gst_element_seek (pipeline, seek->rate,
|
if (gst_element_seek (pipeline, seek->rate,
|
||||||
seek->format, seek->flags,
|
seek->format, seek->flags,
|
||||||
seek->start_type, seek->start,
|
seek->start_type, seek->start,
|
||||||
@ -426,7 +427,6 @@ _execute_action (GstValidateScenario * scenario, ScenarioAction * act)
|
|||||||
"Could not seek to position %" GST_TIME_FORMAT,
|
"Could not seek to position %" GST_TIME_FORMAT,
|
||||||
GST_TIME_ARGS (priv->seeked_position));
|
GST_TIME_ARGS (priv->seeked_position));
|
||||||
}
|
}
|
||||||
priv->seeked_position = (seek->rate > 0) ? seek->start : seek->stop;
|
|
||||||
|
|
||||||
} else if (act->type == SCENARIO_ACTION_PAUSE) {
|
} else if (act->type == SCENARIO_ACTION_PAUSE) {
|
||||||
PauseInfo *pause = (PauseInfo *) act;
|
PauseInfo *pause = (PauseInfo *) act;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user