timeAt method

double timeAt(
  1. Duration t
)

The clip's own time at timeline moment t, in seconds — held at the block's ends.

Implementation

double timeAt(Duration t) {
  var into = t - at;
  if (into < Duration.zero) into = Duration.zero;
  if (into > length) into = length;
  var run = reverse ? length - into : into;
  return offset.inMicroseconds / 1e6 + run.inMicroseconds / 1e6 * speed;
}