Commands Used with the IMGCTRL, IMGOP and PICFILL Functions |
Crops the selected image
rc=IMGOP(task-id, 'CROP', start-x, start-y, end-x,
end-y);
|
region-id=PICFILL(graphenv-id, type, ulr, ulc,
lrr, lrc, source<, 'CROP'<, arguments>>);
|
-
start-x
-
is the row number of the upper corner.
Type: Numeric
-
start-y
-
is the column number of the upper corner.
Type: Numeric
-
end-x
-
is the row number of the lower corner.
Type: Numeric
-
end-y
-
is the column number of the lower corner.
Type: Numeric
The start-x, start-y, end-x, and
end-y points use units of pixels and are included in the new
image. The top left corner of the image is (0,0).
Display an image and then crop it:
name=lnamemk(1,path);
rc=imgop(task-id,'SELECT',1);
rc=imgop(task-id,'READ_PASTE',1,1,name);
if (crop eq 1) then
do;
rc=imgop(task-id,'CROP',ucx,ucy,lcx,lcy);
rc=imgop(task-id,'PASTE',1,1);
end;
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.