Skip to main content
enumConversionMode

Values

FIT

Scales the original to fit inside the canvas, keeping its proportions, so one side can come out shorter than the canvas.

FILL_BACKGROUND

Fits the original inside the canvas minus paddingPercent on each side and fills the rest with background when it's set, so the output is the full canvas.

CROP

Scales the original to cover the canvas, keeping its proportions, and crops what's left over from the centre.

AUTO

Crops when the original and the canvas are both landscape or both portrait, and fits otherwise.