Effacer les filtres
Effacer les filtres

How to save multiple images in a loop without over writing the previous ones?

1 vue (au cours des 30 derniers jours)
I sub-divided 112 images into 16 images each so that I can get 1792 sub-images at the end. Now when I am saving these images using file_name=sprintf('%d.tiff',sliceNumber); imwrite(oneBlock, file_name); in a loop; only 16 images are saved, over writing the previous images, how can I save all the 1792 images?

Réponse acceptée

Mahdi
Mahdi le 21 Mai 2014
Have you considered creating a 3D matrix with pages? Something like initializing a loop variable for each image? For example:
for i=1:16 %the 16 images you have
MatSave(:,:,i)=[] %The matrix that you want to save
end

Plus de réponses (0)

Catégories

En savoir plus sur Images dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by