Enable or disabled interlaced mode of the current image

2.7M Downloads / Month

Open Source MIT License

You are viewing the documentation for Intervention Image 2, this version has reached EOL. Please consider upgrading to version 3.

public Intervention\Image\Image interlace([boolean $interlace])

Determine whether an image should be encoded in interlaced or standard mode by toggling interlace mode with a boolean parameter. If an JPEG image is set interlaced the image will be processed as a progressive JPEG.


interlace (optional)

If interlace is set to boolean true the image will be encoded interlaced. If the parameter is set to false interlaced mode is turned off. Default: true

Return Values

Instance of Intervention\Image\Image


// open image
$img = Image::make('public/foo.png');

// enable interlacing

// save image interlaced

// open interlaced image
$img = Image::make('public/interlaced.gif');

// disable interlacing

// save image in standard mode

See also