public static function identify(){ return static::instance()->identify(); }
public function identify($parameter=null){ $imagemagick_data = $this->exec('identify', $this->image_temp); list($full_image_path, $format, $resolution, $geometry, $depth, $class, $file_size, $info1, $info2) = explode(' ', $imagemagick_data[0]); list($width, $height) = explode('x',$resolution); $parameter = strtolower($parameter); switch ($parameter) { case 'image_path': $data = $full_image_path; break; case 'format': $data = $format; break; case 'resolution': $data = $resolution; break; case 'width': $data = $width; break; case 'height': $data = $height; break; case 'geometry': $data = $geometry; break; case 'depth': $data = $depth; break; case 'class': $data = $class; break; case 'full_data': $data = $imagemagick_data[0]; break; case 'file_size': $data = $file_size; default : $data = $resolution; break; } return $data; }
It looks like you're new here. If you want to get involved, click one of these buttons!