← back to roto on ba3a.dev

FrameRate

data class FrameRate(val numerator: Int, val denominator: Int)

Frames per second as the exact fraction numerator / denominator — 30000/1001 for NTSC-rate phone video — so frame times are computed without floating-point drift.

Constructors

Link copied to clipboard
constructor(numerator: Int, denominator: Int)

Types

Link copied to clipboard
object Companion

Parsing.

Properties

Link copied to clipboard

the denominator of frames per second

Link copied to clipboard

the numerator of frames per second

Functions

Link copied to clipboard

The frame whose start is nearest ms; the inverse of startMs.

Link copied to clipboard
fun startMs(index: Int): Long

When frame index of a clip starts, in whole milliseconds from the clip's first frame.

Link copied to clipboard
open override fun toString(): String

numerator/denominator, the form ffmpeg and ffprobe use.