+ double length = edl->tracks->total_playable_length();
+ double frame_period = 1.0 / edl->session->frame_rate;
+ double start = edl->local_session->get_selectionstart(1);
+ double end = edl->local_session->get_selectionend(1);
+
+ displacement = 0;
+ if( use_inout ) {
+ if( edl->local_session->inpoint_valid() )
+ start_position = edl->local_session->get_inpoint();
+ if( edl->local_session->outpoint_valid() )
+ end_position = edl->local_session->get_outpoint();
+ }
+ else if( !EQUIV(start, end) ) {
+ start_position = start;
+ end_position = end;
+ }
+ else {
+ switch( command ) {