Did you read the parameter list and/or top box in the manual?
That function takes a source location and width/height as well as a destination location and width/height. First sentence of the last paragraph in the Description box says:
PHP Manual wrote:If the source and destination coordinates and width and heights differ, appropriate stretching or shrinking of the image fragment will be performed.