← back to roto on ba3a.dev

ZoneShading

@Serializable
data class ZoneShading(val low: Double, val high: Double, val steps: Int)

How one zone is shaded: lightness low to high split evenly into steps steps, step 0 the darkest. Fixed for the whole clip, so one pixel colour takes one step in every frame.

Constructors

Link copied to clipboard
constructor(low: Double, high: Double, steps: Int)

Properties

Link copied to clipboard

the lightness at the top of the range

Link copied to clipboard
val low: Double

the lightness at the bottom of the range

Link copied to clipboard
val steps: Int

how many ramp steps the range is split into

Functions

Link copied to clipboard
fun step(lightness: Double): Int

The step, 0..steps - 1, a pixel of OKLab lightness takes; outside the range it clamps.