trait CommonAdjustmentTrait

Trait CommonAdjustmentTrait

Methods

brightness(int $level = null)

Adjusts the brightness.

contrast(int $level = null)

Adjusts the contrast.

saturation(int $level = null)

Adjusts the color saturation.

gamma(int $level = null)

Adjusts the gamma level.

by3dLut(string $lutId = null)

Applies the 3D LUT file to the asset.

generic(string $name, mixed ...$args)

Applies any effect.

Details

static LevelEffectAction brightness(int $level = null)

Adjusts the brightness.

Parameters

Name Type Description
$level int The level of brightness (Range: -99 to 100, Server default: 80)

Return Value

LevelEffectAction

static LevelEffectAction contrast(int $level = null)

Adjusts the contrast.

Parameters

Name Type Description
$level int The level of contrast (Range: -100 to 100, Server default: 0)

Return Value

LevelEffectAction

static LevelEffectAction saturation(int $level = null)

Adjusts the color saturation.

Parameters

Name Type Description
$level int The level of color saturation (Range: -100 to 100, Server default: 80).

Return Value

LevelEffectAction

static LevelEffectAction gamma(int $level = null)

Adjusts the gamma level.

Parameters

Name Type Description
$level int The level of gamma (Range: -50 to 150, Server default: 0).

Return Value

LevelEffectAction

static LutLayer by3dLut(string $lutId = null)

Applies the 3D LUT file to the asset.

Parameters

Name Type Description
$lutId string The 3D LUT file id

Return Value

LutLayer

See also

https://cloudinary.com/documentation/image_transformations#applying_3d_luts_to_images

static EffectAction generic(string $name, mixed ...$args)

Applies any effect.

This is a generic way to apply an effect. For example, you could set $name to "gamma" and $args to 50, and this would have the same effect as calling gamma(50).

Parameters

Name Type Description
$name string The effect name.
...$args mixed The qualifiers of the effect.

Return Value

EffectAction