public function resize(int $width, int $height, bool $maintainRatio = false, string $masterDim = 'auto')
	{
		// If the target width/height match the source, then we have nothing to do here.
		if ($this->image->origWidth === $width && $this->image->origHeight === $height)
		{
			return $this;
		}

		$this->width  = $width;
		$this->height = $height;

		if ($maintainRatio)
		{
			$this->masterDim = $masterDim;
			$this->reproportion();
		}

		return $this->_resize($maintainRatio);
	}
public function resize(int $width, int $height, bool $maintainRatio = false, string $masterDim = 'auto')
	{
		// If the target width/height match the source, then we have nothing to do here.
		if ($this->image->origWidth === $width && $this->image->origHeight === $height)
		{
			return $this;
		}

		$this->width  = $width;
		$this->height = $height;

		if ($maintainRatio)
		{
			$this->masterDim = $masterDim;
			$this->reproportion();
		}

		return $this->_resize($maintainRatio);
	}
public function resize ( int $ width , int $ height , bool $ maintainRatio = false , string $ masterDim = 'auto' ) { // If the target width/height match the source, then we have nothing to do here. if ( $ this -> image -> origWidth === $ width && $ this -> image -> origHeight === $ height ) { return $ this ; } $ this -> width = $ width ; $ this -> height = $ height ; if ( $ maintainRatio ) { $ this -> masterDim = $ masterDim ; $ this -> reproportion ( ) ; } return $ this -> _resize ( $ maintainRatio ) ; }
Resize the image

@param integer $width
@param integer $height
@param boolean $maintainRatio If true, will get the closest match possible while keeping aspect ratio true.
@param string  $masterDim

@return BaseHandler
Resize the image