Sat 12 Aug 2017 03:09:55 PM UTC, original submission:
Running the montage function on a series of greyscale images returns the following error
octave> montage({"grey1.png","grey2.png"})
error: montage: A(I): index out of bounds; value 2 out of bound 1
error: called from
montage at line 146 column 39
The culprit line 146 is
[images(:,:,:,page_range), map] = imread (img_info(idx).Filename, 1:nPages);
and it looks to me like it should be
[images(:,:,:,page_range), map] = imread (img_info.Filename, 1:nPages);
as img_info is the current image according to the earlier line
img_info = infos{idx};
Cheers! -Tyson
PS: The earlier check on line 144
if (size (images, 3) == 1 || all (strcmp {img_info(:).ColorType}, "truecolor")))
also looks suspect to me as again img_info is the current image info and not the collection of image infos.
|