-
Notifications
You must be signed in to change notification settings - Fork 20
Description
First of all, many thanks for this extremely useful tool - it's been a game-changer for me when working with multi-gigabyte tiff files in MATLAB.
I was wondering if you'd consider adding functions to slice and concatenate images without loading the entire file. As a trivial example, suppose I have a TIFFStack object with size [600, 1200, 500] and I want to pass just half of it to another function. I would be tempted to do something like
smallTIFFStack = bigTIFFStack(:,1:600,:);
but this loads everything into memory, when what I want is a new TIFFStack object that just references the portion of the image I selected.
It also would be nice to be able to concatenate two TIFFStack objects, for cases when my image acquisition software has split a very long timeseries into multiple files:
`>> size(bigTIFFStack1)
ans = 600 1200 4000
size(bigTIFFStack2)
ans = 600 1200 3745
evenBiggerTIFFStack = cat(3, bigTIFFStack1, bigTIFFStack2;
size(evenBiggerTIFFStack)
ans = 600 1200 7745`
If you don't have time to do this, I'd be willing to work on the coding, but I'd need some help figuring out where to start. I am proficient with MATLAB but don't really know anything about how it deals with memory-mapped files.