Skip to main content

VIUCraft Documentation

Home Getting Started User Guides API Reference Image Processing Integration Guides Best Practices Resources Support AI Integration Playground URL Builder

Resize & Crop

On This Page

VIUCraft provides 4 operations for controlling image dimensions.

resize

Resize to specific dimensions or by scale factor.

ParamRangeDescription
width1–10000Target width in pixels
height1–10000Target height in pixels
forceboolIgnore aspect ratio
scale0.1–4.0Scale factor (overrides width/height)
Code
/resize-800-600/          # fit within 800x600
/resize-800-600-force/    # exact 800x600
/resize_scale_1.5/        # scale up 150%

crop

Extract a region from the image.

ParamRangeDescription
left0–10000Left offset
top0–10000Top offset
width1–10000Crop width
height1–10000Crop height
Code
/crop-100-50-500-300/    # left-top-width-height

thumbnail

Smart thumbnail with crop strategy and optional letterbox.

ParamDescription
widthThumbnail width (50–10000)
heightThumbnail height (50–10000)
cropStrategy: centre, entropy, attention, none
backgroundLetterbox fill color when crop=none
Code
/thumb-300-300-attention/         # smart crop
/thumb-300-300-none-F5F5F5/       # letterbox with gray bg

smartcrop

Content-aware cropping using AI detection strategies.

ParamDescription
widthTarget width (50–10000)
heightTarget height (50–10000)
strategyattention, entropy, centre, high, low
Code
/scrop-500-300-entropy/    # crop to detail-rich area

Was this helpful?

On This Page