- FAQ: How to process a sequence of files (link)
- https://www.mathworks.com/help/matlab/import_export/process-a-sequence-of-files.html
Save images in a loop
3 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Maria Jaramillo
el 9 de Jul. de 2018
I currently have a program that creates an image and then saves it in a folder. (uiputfile) it works, but I need a way to do the same but continuously using a loop. I need the program to go through completely and at the end save the file and then do the same again. Each time the file will have a different name. I have a name giving function that saves it it nameString. Also I have the location folder using the cd function. I just need the images to be saved without me having to hit the save button.
0 comentarios
Respuesta aceptada
Jan
el 9 de Jul. de 2018
Editada: Jan
el 9 de Jul. de 2018
See:
BaseFolder = tmpdir;
for k = 1:100
...
FileName = fullfile(BaseFolder, sprintf('Image%04d.png'));
imwrite(Data, FileName);
end
0 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Environment and Settings en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!