Problem with rezising images ...

See all posts See thread Reply

Re: Hmmm.... new!
by DaveW, 16 years ago
That said....

I've just downloaded the new version, anc exactly the same problem.

This is my code....
$t = CCGetParam("top") ;
$l = CCGetParam("left") ;
$h = CCGetParam("height") ;
$w = CCGetParam("width") ;
$rh = CCGetParam("reqh") ;
$rw = CCGetParam("reqw") ;

$b = $handle->image_src_y - ($t + $h) ;
$r = $handle->image_src_x - ($l + $w) ;

$handle->image_crop 	= array($t, $r, $b, $l);
$handle->image_resize          = true;
$handle->image_y	       = $rh;
$handle->image_x               = $rw;
$handle->image_convert         = 'jpg';
$handle->jpeg_quality          = 80;

$handle->Process('../tmp/') ;

If I comment out the resize, the crop works fine (and as expected)

If I comment out the crop, the resize works as expected!

Together, I get a jpeg image of 1x1

???????

Please helpReply