Too many IDAT's found.The image data may be corrupt.MA​TLAB:image​sci:png:to​oManyIDATs​Data'

조회 수: 4 (최근 30일)
I have written a code to clean my image data and move the files causing error into other file.
imageDir = 'C:\Users.......\paved';
imgList = dir(imageDir);
destFolder = 'C:\Users.....\Dpaved';
for i = 3: numel(imgList)
img = fullfile(imgList(1).folder,imgList(i).name);
lastwarn = [lastmsg, lastid] ;
try
I = imread(img);
catch MException
movefile(img,destFolder); %[status,message,messageId] = movefile(img,destFolder,'f');
end
end
-----------------------------------------------------------------------------------------------------------------------------------
Following errors arrive
Warning: PNG library warning: Ignoring bad adaptive filter type.
> In readpngutil (line 12)
In readpng (line 32)
In imread/call_format_specific_reader (line 447)
In imread (line 440)
In imageCleanup (line 11)
Warning: PNG library warning: Extra compressed data..
> In readpngutil (line 12)
In readpng (line 32)
In imread/call_format_specific_reader (line 447)
In imread (line 440)
Warning: Too many IDAT's found. The image data may be corrupt.
> In readpngutil (line 13)
In readpng (line 32)
In imread/call_format_specific_reader (line 447)
In imread (line 440)
In imageCleanup (line 11)

답변 (0개)

카테고리

Help CenterFile Exchange에서 Read, Write, and Modify Image에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by