Image processing

조회 수: 2 (최근 30일)
Fish Out Of Water :D
Fish Out Of Water :D 2011년 10월 7일
p ='C:\MATLAB\R2010b';
fn = dir(fullfile(p,'*.jpeg'));
trh = 0.1;
for i = 1:length(fn)
a = imread ( 'C:\MATLAB\R2010b',jpeg);
imwrite(im7,['C:\MATLAB\R2010b\New folder','C:\MATLAB\R2010b']);
procImage([p '\' fn(i).name],trh);
end;
// procImage is my function
Hi this is the code i've tried to write out.... I'm finding a method to save the batch of image that i've processed in the function as stated.
imwrite did not allow me save the image.
ARIGATO FOR THE HELP !

답변 (1개)

Walter Roberson
Walter Roberson 2011년 10월 7일
p ='C:\MATLAB\R2010b';
q ='C:\MATLAB\R2010b\New folder';
fn = dir(fullfile(p,'*.jpeg'));
trh = 0.1;
for i = 1:length(fn)
jpeg = fn(i).name;
fullinputname = fullfile(p,jpeg);
fulloutputname = fullfile(q,jpeg);
[im7, im7map] = imread(fullinputname);
imwrite(im7,im7map, q);
procImage(fullinputname, trh);
end;
It is, though, not clear why you do not just copy the files to the new directory, cd() to it, and process the images there ?

카테고리

Help CenterFile Exchange에서 Images에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by