Imagick::charcoalImage
Imagick::clear
The Imagick class
PHP Manual

# Imagick::chopImage

(PECL imagick 2.0.0)

Imagick::chopImage — Removes a region of an image and trims

### 설명

bool Imagick::chopImage ( int `$width` , int `$height` , int `$x` , int `$y` )
Warning

이 함수는 현재 문서화 되어있지 않습니다; 인수 목록만을 제공합니다.

Removes a region of an image and collapses the image to occupy the removed portion.

### 인수

`width`

  Width of the chopped area

`height`

  Height of the chopped area

`x`

  X origo of the chopped area

`y`

  Y origo of the chopped area

### 반환값

성공시에 `TRUE`를 반환합니다.

### 오류/예외

오류시에 ImagickException이 발생합니다.

### 예제

Example #1 Using Imagick::chopImage():

Example of using Imagick::chopImage

`<?php
/* Create some objects */
$image = new Imagick();
$pixel = new ImagickPixel( 'gray' );
/* New image */
$image->newImage(400, 200, $pixel);
/* Chop image */
$image->chopImage(200, 200, 0, 0);
/* Give image a format */
$image->setImageFormat('png');
/* Output the image with headers */
header('Content-type: image/png');
echo $image;
?>`

### 참고

- Imagick::cropImage() - Extracts a region of the image

Imagick::charcoalImage
Imagick::clear
The Imagick class
PHP Manual