Posted by
rmd06 on
Jul 19, 2017; 1:56am
URL: http://imagej.273.s1.nabble.com/Cannot-use-TurboReg-plugin-by-using-matlab-tp5017668p5019084.html
Hi, LCY
I copy your code and runy in my Matlab to register a stack tif to a single tif.
After I run, only two slice were registered, not the whole stack.
Do you know what's the possible reason? Thanks.
code is below: Miji();
imgpath = 'D:\Lab\tempdate\123\2X2-MB-epac\ATM-Bad-1\Stack.tif';
MIJ.run('Open...',['path=[',strrep(imgpath,'\','\\'),']']);
imgpath = 'D:\Lab\tempdate\123\2X2-MB-epac\ATM-Bad-1\AAA.tif';
MIJ.run('Open...',['path=[',strrep(imgpath,'\','\\'),']']);
aSize = size(MIJ.getCurrentImage);
width = aSize(2);
height = aSize(1);
MIJ.run('TurboReg ',... ['-align -window ','AAA.tif',... ' 0 0 ',num2str(width),' ',num2str(height),' ',... '-window ','Stack.tif',' 0 0 ',num2str(width),' ',num2str(height),' ',... '-rigidBody ',num2str(width/2),' ',num2str(height/2),' ',num2str(width/2),' ',num2str(height/2),' ',... '0 ',num2str(height/2),' 0 ',num2str(height/2),' ',num2str(width-1),' ',num2str(height/2),' ',num2str(width-1),' ',num2str(height/2),' ','-showOutput']);
_____________________________________ Sent from
http://imagej.1557.x6.nabble.com ΓΏ