Login  Register

Re: Create Hyperstack - Composite Problem

Posted by Greg on Mar 02, 2015; 2:50pm
URL: http://imagej.273.s1.nabble.com/Create-Hyperstack-Composite-Problem-tp5011826p5011829.html

So in the end I solved the Problem by calling the "Stack to Hyperstack" Plugin directly:

# new empty Stack                                                                                    
Stack = ImageStack(width,height)

for sliceIndex in range(start,3*NFrames +1):
    IJ.showProgress(sliceIndex,3*NFrames)
    c = sliceIndex%3
    if c == 0:
        c = 3
    print 'slice ',sliceIndex,c
    ip = bf.getProcessor(sliceIndex)
    Stack.addSlice(None,ip)
    # stack.setProcessor(ip,sliceIndex)                                                              

name = 'Frames ' + str(start) + '-' + str(end) + ' ' + filename
imp = ImagePlus(name,Stack)

IJ.run(imp,"Stack to Hyperstack...", "order=xyczt(default) channels=3 slices=1 frames="+str(NFrames)\
+" display=Color");