Horizontal bands of one layer, each scrolling at its own factor.
bands = Cauldron2D.Parallax.Bands.new([{0..5, 0.1}, {6..11, 0.45}, {12..23, 0.9}])
Cauldron2D.Parallax.Bands.roll(raster, bands, {focus_x, focus_y}, tile)Ranges are tile rows from the top of the picture, read in order, the first range holding
a row deciding it. A row no range covers does not move. A band reads the focus itself, so
a layer that carries bands wants a factor of 0.0 on the axis they move along.
Summary
Functions
The factor for tile row row, or 0.0 where no band covers it.
Bands from [{tile_rows, factor}].
raster with every band's pixel rows rolled sideways by its own share of focus.
Types
Functions
The factor for tile row row, or 0.0 where no band covers it.
Bands from [{tile_rows, factor}].
@spec roll(FrenchCurve.Raster.t(), t() | nil, {number(), number()}, pos_integer()) :: FrenchCurve.Raster.t()
raster with every band's pixel rows rolled sideways by its own share of focus.