Skip to content

Commit 3803ac1

Browse files
committed
imStacks/readstack.m: fix import of TIF images saved with ImageJ larger than 4GB
1 parent b7615d9 commit 3803ac1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

matImage/imStacks/readstack.m

+3-2
Original file line numberDiff line numberDiff line change
@@ -435,9 +435,10 @@
435435
tokens = regexp(infos.ImageDescription, '\n', 'split');
436436

437437
% consider multiple if number of images is larger than 1
438-
ind = find(strcmpi(tokens, 'image'));
438+
ind = find(strncmpi(tokens, 'images', 6));
439439
if ~isempty(ind)
440-
nImages = str2num(tokens{ind+1}); %#ok<ST2NM>
440+
token = tokens{ind};
441+
nImages = str2num(token(8:end)); %#ok<ST2NM>
441442
if nImages > 1
442443
b = true;
443444
end

0 commit comments

Comments
 (0)