← back to roto on ba3a.dev

Package-level declarations

Types

Link copied to clipboard
@Serializable
data class Clip(val action: String, val facing: String, val source: String, val trim: TimeRange?, val plate: PlateSource = PlateSource.ClipMedian, val mask: MaskSettings = MaskSettings(), val root: RootSettings = RootSettings(), val depth: DepthSettings = DepthSettings(), val cycle: CycleSettings = CycleSettings(), val markers: List<Int>? = null, val fixes: List<BrushStroke> = emptyList(), val zoning: ZoneSettings = ZoneSettings(), val shading: ShadeSettings = ShadeSettings(), val draft: DraftSettings = DraftSettings(), val loop: Boolean = true, val mirror: Boolean = false, val model: String? = null, val retime: Retime = Retime(), val godotSpeed: Int? = null)

One action filmed from one facing: a trimmed range of a source video in the profile's sources/ folder, or, with no trim, a still: the one frame of a source photo, which needs a photo of the empty wall as its plate and runs through every stage the same way. plate says where its empty background comes from, mask how its figure is told apart from it, root how the figure is tracked and held still, and cycle how its key frames are proposed; markers, once the artist has set them, replace that proposal as KeyFrames boundaries. fixes are the artist's brush strokes on the masks of key frames. zoning splits the figure into zones, each shaded with one of the profile's ramps across the lightness range shading sets, then finished as draft says. loop says whether the published animation repeats; mirror opts this clip in to also being published, mirrored, as the facing roto.json pairs it with; model names the profile's model clip it follows, if any.

Link copied to clipboard
@Serializable
sealed interface PlateSource

Where a clip's clean plate — the empty background its figure is masked against — comes from. Stored in profile.json as an object whose type names the kind.

Link copied to clipboard
@Serializable
data class Profile(val ramps: List<String> = emptyList(), val scale: ScaleSettings? = null, val clips: List<Clip> = emptyList(), val variant: VariantOf? = null)

One character (or prop) of a consuming project: the clips filmed for it, the palette ramps it uses, and the scale it is drawn at once the artist has marked it. Stored as profile.json in the profile's library folder; the folder name is the profile id, so the id is not repeated inside the file. Validated on construction, including that every zone of every clip uses one of ramps.

Link copied to clipboard

Reads and writes Profile as profile.json, which sits in the profile's library folder; a bad file is a ProfileException.

Link copied to clipboard
class ProfileException(message: String, cause: Throwable? = null) : IOException

A profile.json that is malformed or fails Profile's validation.

Link copied to clipboard
class ProfileFolder(val path: Path)

The layout of one profile's folder in the library:

Link copied to clipboard
class ProfileRepository(library: Path, projectId: String)

The profiles of one project in the library folder: <library>/<projectId>/<profile id>/, each a ProfileFolder. The library lives outside every repository and is shared by all projects; the project id comes from the project's roto.json. Profile ids follow SafeName, since they become folder names and the {profile} value in output paths.

Link copied to clipboard
@Serializable
data class TimeRange(val startMs: Long, val endMs: Long)

A half-open range of a video's timeline, startMs inclusive to endMs exclusive.