1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
|
input_folder = ...; % Enter name of folder from which you want to upload pictures with full path
output_folder = ...;
filenames = dir(fullfile(input_folder, '*.jpg')); % read all images with specified extention, its jpg in my case
n = numel(filenames); % count total number of photos present in that folder
Outputs=n;
dir=output_folder;
for i =1:nImages
%tu met la lecture de tes images et la modification ((dans mon cas j'ai changé les images jpg en bmp)
filename = [sprintf('%03d',i) '.bmp'];
fullname = fullfile(output_folder,filename);
imwrite(image8,fullname,'bmp') % Write out to a bmp file (c mon cas)
end |
Partager