How to extract a ROI?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

How to extract a ROI?

Juanjo Vega
Hello everyone!

I'm trying to extract a ROI programmatically. I mean, I'm developing a
plugin and I need to create a new image with the previously selected
area from another image.

I can create the image with the right size (the same as the ROI), but
I'm having problems copying the ROI (the new image is not modified after
it is created). Maybe somebody did it before and can help me, or maybe
I'm loosing an easier way...

Thanks!

--
Juanjo Vega ([hidden email])

Unidad de Biocomputación. Laboratorio B-13.
Centro Nacional de Biotecnología. CNB-CSIC.
C\ Darwin, 3. Campus de Cantoblanco.
Universidad Autónoma de Madrid.
28049, Madrid, Spain.

http://www.cnb.csic.es
http://www.biocomp.cnb.uam.es

+34 91 585 4510


"Las mejores almas son capaces de los mayores vicios como de las mayores virtudes, y aquellos que caminan despacio por el camino recto pueden llegar más lejos que los que corren pero se apartan de él." - Discurso del Método, René Descartes.
Reply | Threaded
Open this post in threaded view
|

Re: How to extract a ROI?

Stephan Saalfeld
Be lazy and do:

IJ.run("Copy");
IJ.run("Internal Clipboard");

Best,
Stephan


On Mon, 2009-05-18 at 14:10 +0200, Juanjo Vega wrote:

> Hello everyone!
>
> I'm trying to extract a ROI programmatically. I mean, I'm developing
> a
> plugin and I need to create a new image with the previously selected
> area from another image.
>
> I can create the image with the right size (the same as the ROI), but
> I'm having problems copying the ROI (the new image is not modified
> after
> it is created). Maybe somebody did it before and can help me, or
> maybe
> I'm loosing an easier way...
>
> Thanks!
>
Reply | Threaded
Open this post in threaded view
|

Re: How to extract a ROI?

Juanjo Vega
It works!

To be lazy is cool! :D

By the way... I can't find a programmiug manual for imageJ plugins, just
the manual with the simple examples. Does it exists?

Thanks!

Stephan Saalfeld escribió:

> Be lazy and do:
>
> IJ.run("Copy");
> IJ.run("Internal Clipboard");
>
> Best,
> Stephan
>
>
> On Mon, 2009-05-18 at 14:10 +0200, Juanjo Vega wrote:
>  
>> Hello everyone!
>>
>> I'm trying to extract a ROI programmatically. I mean, I'm developing
>> a
>> plugin and I need to create a new image with the previously selected
>> area from another image.
>>
>> I can create the image with the right size (the same as the ROI), but
>> I'm having problems copying the ROI (the new image is not modified
>> after
>> it is created). Maybe somebody did it before and can help me, or
>> maybe
>> I'm loosing an easier way...
>>
>> Thanks!
>>
>>    
>
>  

--
Juanjo Vega ([hidden email])

Unidad de Biocomputación. Laboratorio B-13.
Centro Nacional de Biotecnología. CNB-CSIC.
C\ Darwin, 3. Campus de Cantoblanco.
Universidad Autónoma de Madrid.
28049, Madrid, Spain.

http://www.cnb.csic.es
http://www.biocomp.cnb.uam.es

+34 91 585 4510


"Las mejores almas son capaces de los mayores vicios como de las mayores virtudes, y aquellos que caminan despacio por el camino recto pueden llegar más lejos que los que corren pero se apartan de él." - Discurso del Método, René Descartes.