# `CauldronGPU.Texture`
[🔗](https://github.com/jaman/cauldron/blob/v0.3.3/cauldron_gpu/lib/cauldron_gpu/texture.ex#L1)

A picture to upload. `pixels` is `width * height` pixels, rows from the top: four bytes
RGBA for `:srgb` (colour pictures) and `:linear` (data such as roughness), eight bytes
(four little-endian half floats) for `:rgba16f`.

    CauldronGPU.Texture.checker(64, 8, {255, 255, 255, 255}, {40, 40, 40, 255})

# `format`

```elixir
@type format() :: :srgb | :linear | :rgba16f
```

# `t`

```elixir
@type t() :: %CauldronGPU.Texture{
  filter: :nearest | :linear,
  format: format(),
  height: pos_integer(),
  mipmaps: boolean(),
  pixels: binary(),
  width: pos_integer(),
  wrap: :repeat | :clamp
}
```

# `checker`

```elixir
@spec checker(pos_integer(), pos_integer(), tuple(), tuple(), keyword()) :: t()
```

A `size`×`size` checkerboard of `squares` squares a side, in two RGBA colours.

---

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