A texture page (a TXTR entry): one packed image that sprites, tilesets and fonts cut
their pictures from through Cauldron2D.GameMaker.Region.
encoding names how the page's bytes are stored: :png, :qoi (GameMaker's QOI
variant), or :bz2_qoi (that, compressed with bzip2). bytes is the page as stored.
decode/1 turns a PNG page into a FrenchCurve.Raster; the other two encodings
return {:error, {:unsupported_encoding, encoding}}.
Summary
Functions
The page as a raster.
Every texture page in the TXTR chunk at at, size bytes long, in order. A PNG
page ends at its IEND; a page in another encoding runs to the next page's bytes or
the chunk's end.
Types
Functions
@spec decode(t()) :: {:ok, FrenchCurve.Raster.t()} | {:error, term()}
The page as a raster.
@spec read_all(binary(), non_neg_integer(), non_neg_integer()) :: [t()]
Every texture page in the TXTR chunk at at, size bytes long, in order. A PNG
page ends at its IEND; a page in another encoding runs to the next page's bytes or
the chunk's end.