Login  Register

Re: How to split image?

Posted by ctrueden on Jul 28, 2006; 6:16pm
URL: http://imagej.273.s1.nabble.com/How-to-split-image-tp3701975p3701976.html

Hi,

Such tasks are exactly what macros are for. Using the Macro Recorder
(Plugins -> Macros -> Record) together with the Built-in Macro Functions
list (http://rsb.info.nih.gov/ij/developer/macro/functions.html), I created
the following macro that does what you ask:

makeRectangle(0, 0, getWidth()/2, getHeight());
run("Copy");
run("Make Inverse");
run("Crop");
run("Internal Clipboard");

-Curtis

On 7/28/06, Ye Chen <[hidden email]> wrote:

>
> Hello,
>
> Is there any  function or plugin in ImageJ available to split one image
> into half from the middle? For example, if I have an image 512 by 512, I
> need to split this image from the middle to get another two new images
> which should be 256 by 512?
>
> Thanks
>