ass_scale_times
Stretch or compress the timing of selected ASS subtitle lines around a fixed origin, adjusting both start and end times by a multiplier.
Instructions
Scale the timing of the selection around an origin.
new = origin + (old - origin) * factor is applied to both the start and
the end of every selected line, so the selection stretches or compresses
while the origin stays put.
Args:
selection: lines to scale (see :func:ass_shift_times).
factor: multiplier, must be > 0.
doc_id: document id.
origin: None/"first" (start of the earliest selected line),
"document" (0), or an explicit millisecond value / time string.
round_ms: round the computed times to whole milliseconds before writing.
Returns:
{"doc_id", "factor", "origin_ms", "origin", "round_ms", "indices", "count", "changes": [{"index", "start_ms", "end_ms", "new_start_ms", "new_end_ms"}], "span": {"before": {"min_start_ms", "max_end_ms", "span_ms"}, "after": {...}}}
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| doc_id | No | ||
| factor | No | ||
| origin | No | ||
| round_ms | No | ||
| selection | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||