CLI
One-shot commands over the same pipeline, no server:
oximg resize photo.jpg 1600 1600 out.webp # fit within 1600x1600; format from the extensionoximg resize photo.jpg 800 800 out.jpg -q 70 # JPEG quality 70 (--preset fast|small for mozjpeg)oximg resize photo.jpg 750 0 out.jpg # width-only: height follows the aspect ratiooximg resize photo.jpg 0 0 out.webp # 0 0 = re-encode at the source's own sizeoximg probe photo.webp # format + stored dimensions, header-onlyoximg probe loop.gif # animated sources also print frames, duration and loop countThe output format is -f/--format, else the <out> extension, else
the source’s own format — the same precedence idea as the server’s
@fmt grammar. The OXIMG_* encode knobs below apply to CLI encodes
the same way. Usage errors exit 2; processing failures exit 1.