How can i display image from array element of cell??
조회 수: 1 (최근 30일)
이전 댓글 표시
im working with color based image retrieval..i have array cell containing list filename..how can i display them in gui using for loop??
댓글 수: 0
채택된 답변
Walter Roberson
2020년 2월 22일
for k=1:numel(fileNm)
This = fileNm{k} ;
if isempty(This) ; continue ; end
imshow(This) ;
pause(3);
end
This assumes that you only want to display the image and that you do not mind if the window keeps changing size. If you want to process the image you would need an imread() step.
댓글 수: 3
Image Analyst
2020년 2월 22일
After imshow(), try title() with the filename
for k = 1 : numel(fileNm)
thisFileName = fileNm{k};
if ~isfile(thisFileName) ; continue ; end
imshow(thisFileName);
caption = sprintf('File %d of %d : "%s"', k, numel(fileNm), thisFileName)
title(caption, 'FontSize', 18);
drawnow;
end
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Image Processing and Computer Vision에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!