class TrimEffect extends LimitedEffectQualifier

Detect and remove image edges whose color is similar to corner pixels.

Methods

__construct($colorSimilarity = null)

Trim constructor.

colorSimilarity(int $colorSimilarity)

Sets the tolerance level for color similarity.

colorOverride(string $colorOverride)

Overrides the corner pixels color with the specified color.

Details

__construct($colorSimilarity = null)

Trim constructor.

Parameters

Name Type Description
$colorSimilarity

TrimEffect colorSimilarity(int $colorSimilarity)

Sets the tolerance level for color similarity.

Parameters

Name Type Description
$colorSimilarity int The tolerance level for color similarity. (Range: 0 to 100, Server default: 10)

Return Value

TrimEffect

TrimEffect colorOverride(string $colorOverride)

Overrides the corner pixels color with the specified color.

Parameters

Name Type Description
$colorOverride string The color to trim as a named color or an RGB/A hex code.

Return Value

TrimEffect