trait QualityBuilderTrait

Trait QualityBuilderTrait

Methods

quality(int $level)

Controls the JPEG, WebP, GIF, JPEG XR and JPEG 2000 compression quality.

chromaSubSampling(string $chromaSubSampling)

Adds an optional qualifier to control chroma subsampling

quantization(int $quantization)

Controls the final quality by setting a maximum quantization percentage

Details

QualityBuilderTrait quality(int $level)

Controls the JPEG, WebP, GIF, JPEG XR and JPEG 2000 compression quality.

Reducing the quality is a trade-off between visual quality and file size.

Parameters

Name Type Description
$level int The quality level. 1 is the lowest quality and 100 is the highest.

Return Value

QualityBuilderTrait

QualityBuilderTrait chromaSubSampling(string $chromaSubSampling)

Adds an optional qualifier to control chroma subsampling

Chroma sub-sampling is a method of encoding images by implementing less resolution for chroma information (colors) than for luma information (luminance), taking advantage of the human visual system's lower acuity for color differences than for luminance

Parameters

Name Type Description
$chromaSubSampling string Chroma sub-sampling value

Return Value

QualityBuilderTrait

QualityBuilderTrait quantization(int $quantization)

Controls the final quality by setting a maximum quantization percentage

Parameters

Name Type Description
$quantization int The quantization level. Is a % (1-100) setting.

Return Value

QualityBuilderTrait

See also

https://cloudinary.com/documentation/video_manipulation_and_delivery#control_the_quality_of_webm_transcoding