Converting 3d image stack to a 1* 1 cell array
이전 댓글 표시
I need to create a 1*1 cell array which has a 3 dimensional (1024*1024*80) array of gray scale values obtained from my image stack.
This is the code I have so far and I am not sure why I cant capture the 3rd dimension but when I run it I can capture 1024*1024 but not the 80 in the z dimension. How can I fix that?
if true
%
clear all
clc
folder = 'E:\Users\bvendra\Desktop\4.13umgs3-14c2before20,30, almost40\20\tif';
D = 'E:\Users\bvendra\Desktop\4.13umgs3-14c2before20,30, almost40\20\tif';
dCell = dir([D,'.tif']);
% NOTE: CHANGE FILETYPE AS APPROPRIATE FOR EACH SEQUENCE (.png, *.bmp, or *.jpg)
N = 80
numRows = ceil(sqrt(N));
IMAGES = cell(1,N);
FNAMEFMT = '%d.tif';
% Load images
for i=1:N
a = imread(sprintf(FNAMEFMT, i));
end
a={a};
save vol01
end
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Convert Image Type에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!