# `mix linocut.import`
[🔗](https://github.com/jaman/cauldron/blob/v0.2.2/linocut/lib/mix/tasks/linocut.import.ex#L1)

Read an image, reduce it to a pixel-art palette, and write it as a `.pic`.

    mix linocut.import sky.png --out art/sky.pic --size 160x96 --colours 12
    mix linocut.import ruins.png --out art/ruins.pic --size 320x64 --key corner

## Options

  * `--out` — where to write the `.pic`, required
  * `--size` — `WIDTHxHEIGHT` to redraw at. Default the picture's own size
  * `--crop` — `X,Y,WIDTH,HEIGHT` of the source to keep, before resizing. Default all
  * `--seam` — `X,Y` pixels of the far edge to fade into the near one so the picture
    tiles, after resizing; the result loses that many pixels on each axis. Default none
  * `--colours` — how many colours the palette may hold. Default `16`
  * `--key` — a colour to make clear, as `#rrggbb` or `corner` for the top-left pixel's
    colour. Default none
  * `--tolerance` — how far from `--key` a colour may be and still be cleared, as a
    distance in each channel. Default `20`
  * `--alpha` — the alpha at or above which a pixel counts as opaque. Default `128`
  * `--nearest` — resample by taking one pixel rather than averaging, which keeps hard
    pixel art hard

---

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