How I can save the figures plotted from multiple cycles into a specific folder created and make a movie from the images sequence

3 次查看(过去 30 天)
I have 100 cycle of images in loop i, but the figure showed the latest cycle only. How to display the figures in every cycle and save all of the figures in 100 cycles to a specific folder. The saved images then animated like a video in matlab. Help me!!
for i= LastImage:-1:StartingImage
n = i - StartingImage;
CAIT = RepRate*n;
Image(:,:,i) = Readim7(thisFolder, baseFileNames, i);
%% BG Subtraction
Subtracted(:,:,i) = Image(:,:,i)-avg_BG;
%% Frequency filtering
[FFT_Filtered_Image(:,:,i)] = ApplyFFT(Subtracted(:,:,i), Mask);
%% Spatial Filtering
Median_filtered_Image(:,:,i)= medfilt2(FFT_Filtered_Image(:,:,i), [3 3]);
ProcessedImage(:,:,i) = Median_filtered_Image(:,:,i);
%% Automatic dynamic thresholding
[I_avg, Offset_L, New_TH] = ComputeTH(ProcessedImage(:,:,i), SC, Pre_TH);
%% Binarization Process
[FlameRadiusInMm(:,i), Pre_TH, boundary_thin(:,:,i)]...
= BinarizeImage(ProcessedImage(:,:,i), New_TH, PixelSize);
figure;
subplot(1,2,1);
imshow(ProcessedImage(:,:,i));
subplot(1,2,2);
imshow(boundary_thin(:,:,i));
  10 个评论

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Images 的更多信息

产品


版本

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by