Ragex.Image (Ragex v0.28.0)

View Source

Core image manipulation functions backed by the Image library (Vix/libvips).

Summary

Functions

Apply visual filters / enhancements.

Generate a circular, squircle, or square avatar image.

Compare two images for visual diff/similarity.

Composite (overlay) an image on top of a base image.

Convert image format (e.g. PNG, JPEG, WebP, AVIF, TIFF, GIF).

Crop an image by bounding box or auto-trim.

Get detailed information and metadata for an image file.

Resize an image by scale factor, width/height dimensions, or crop focus.

Rotate or flip an image.

Functions

apply_filter(path, filter_name, opts \\ [])

Apply visual filters / enhancements.

avatar(path, output_path, opts \\ [])

Generate a circular, squircle, or square avatar image.

compare(image_a_path, image_b_path, opts \\ [])

Compare two images for visual diff/similarity.

composite(base_path, overlay_path, output_path, opts \\ [])

Composite (overlay) an image on top of a base image.

convert(path, output_path, opts \\ [])

Convert image format (e.g. PNG, JPEG, WebP, AVIF, TIFF, GIF).

crop(path, opts)

Crop an image by bounding box or auto-trim.

draw_text(path, output_path, text, opts \\ [])

Render text onto an image.

info(path)

Get detailed information and metadata for an image file.

resize(path, opts)

Resize an image by scale factor, width/height dimensions, or crop focus.

rotate(path, opts)

Rotate or flip an image.