public function same($expectedImage, $compareImage)
	{
		$metric = $this->_createOption(Metric::class, 'AE');
		$cmd    = 'compare ' . $metric . $expectedImage . ' ' . $compareImage . $this->redirectDefaultErrorResponse;

		return (int)`$cmd` === 0;
	}
	

	/**
	 * Creates a comparison image.
	 *
	 * @param string $compareImage    Expected image.
	 * @param string $actualImage     Current image to compare.
	 * @param string $resultImageName Name of the resulting comparison image.
	 * @param string $resultImageDir  (Optional) Path to directory of result images.
	 *
	 * @return mixed
	 * @throws \ImageMagick\Exceptions\InvalidOptionValueException
	 */
	public function createComparisonImage($compareImage,
	                                      $actualImage,
	                                      $resultImageName,
	                                      $resultImageDir = '.')
	{
		$compose = $this->_createOption(Compose::class, 'src');

		$resultDirectory = rtrim($resultImageDir, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;
		$cmd             = 'compare ' . $compareImage . ' ' . $actualImage . ' ' . $compose . $resultDirectory
		                   . $resultImageName . '.png';

		return `$cmd`;
	}
public function same($expectedImage, $compareImage)
	{
		$metric = $this->_createOption(Metric::class, 'AE');
		$cmd    = 'compare ' . $metric . $expectedImage . ' ' . $compareImage . $this->redirectDefaultErrorResponse;

		return (int)`$cmd` === 0;
	}
	

	/**
	 * Creates a comparison image.
	 *
	 * @param string $compareImage    Expected image.
	 * @param string $actualImage     Current image to compare.
	 * @param string $resultImageName Name of the resulting comparison image.
	 * @param string $resultImageDir  (Optional) Path to directory of result images.
	 *
	 * @return mixed
	 * @throws \ImageMagick\Exceptions\InvalidOptionValueException
	 */
	public function createComparisonImage($compareImage,
	                                      $actualImage,
	                                      $resultImageName,
	                                      $resultImageDir = '.')
	{
		$compose = $this->_createOption(Compose::class, 'src');

		$resultDirectory = rtrim($resultImageDir, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;
		$cmd             = 'compare ' . $compareImage . ' ' . $actualImage . ' ' . $compose . $resultDirectory
		                   . $resultImageName . '.png';

		return `$cmd`;
	}
public function same ( $ expectedImage , $ compareImage ) { $ metric = $ this -> _createOption ( Metric :: class , 'AE' ) ; $ cmd = 'compare ' . $ metric . $ expectedImage . ' ' . $ compareImage . $ this -> redirectDefaultErrorResponse ; return ( int ) `$cmd` === 0;
	}
	

	/**
	 * Creates a comparison image.
	 *
	 * @param string $compareImage    Expected image.
	 * @param string $actualImage     Current image to compare.
	 * @param string $resultImageName Name of the resulting comparison image.
	 * @param string $resultImageDir  (Optional) Path to directory of result images.
	 *
	 * @return mixed
	 * @throws \ImageMagick\Exceptions\InvalidOptionValueException
	 */
	public function createComparisonImage($compareImage,
	                                      $actualImage,
	                                      $resultImageName,
	                                      $resultImageDir = '.')
	{
		$compose = $this->_createOption(Compose::class, 'src');

		$resultDirectory = rtrim($resultImageDir, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;
		$cmd             = 'compare ' . $compareImage . ' ' . $actualImage . ' ' . $compose . $resultDirectory
		                   . $resultImageName . '.png';

		return `$cmd` ; }
Compares two images.
Returns true if they looking equal and false otherwise.

@param string $expectedImage Path to the expected image.
@param string $compareImage  Path to compare image.

@return bool
@throws \ImageMagick\Exceptions\InvalidOptionValueException
Compares two images . Returns true if they looking equal and false otherwise .