# `Cauldron3D.Frame.Pixels`
[🔗](https://github.com/jaman/cauldron/blob/v0.2.2/cauldron_3d/lib/cauldron_3d/frame/pixels.ex#L1)

Whole runs of RGBA pixels, four bytes each.

    Cauldron3D.Frame.Pixels.lay(under, above)
    Cauldron3D.Frame.Pixels.through(pixels, table)

`available?/0` says whether the C library loaded. Where it did not the same bytes are
made in Elixir.

# `available?`

```elixir
@spec available?() :: boolean()
```

Whether the library is loaded and pixels are worked in C.

# `lay`

```elixir
@spec lay(binary(), binary()) :: binary()
```

`above` laid over `under`, both RGBA of the same length: where `above`'s alpha is 255
its colour, where 0 `under`'s pixel, and otherwise each channel
`div(above * a + under * (255 - a), 255)` with `under`'s alpha kept.

# `through`

```elixir
@spec through(binary(), binary()) :: binary()
```

`pixels` with each red, green and blue byte `v` replaced by byte `v` of the 256-byte `table`; alpha kept.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
