Note: You must be registered in order to post a reply. To register, click here. Registration is FREE!
T O P I C R E V I E W
aleatprog
Posted - Oct 24 2020 : 11:34:29 Occasionally, the usage of TImageEnMIO.SaveToFileTIFF(FileName, True) or TImageEnMIO.SaveToFile(FileName, ioTIFF, True) generates an incomplete, 174 byte sized TIF File which can't be opened.
Curious: Without closing the application and after saving the TImageEnMView Bitmaps in other formats (e.g. JPG, PDF) the saving in TIF format finally succeeds.
Has anyone made a similar experience with TImageEnMIO.SaveToFileTIFF and got a workaround to fix this behaviour?
Al
ImageEn 9.2 Delphi 10.3
4 L A T E S T R E P L I E S (Newest First)
xequte
Posted - Oct 25 2020 : 23:04:07 I tried to reproduce as follows, but did not experience any issues:
ImageEnMView1.AppendImage('D:\im.jpg');
ImageEnMView1.AppendImage('D:\alpha.png');
ImageEnMView1.AppendImage('D:\im2.jpg');
ImageEnMView1.AppendImage('D:\im3.jpg');
ImageEnMView1.AppendImage('D:\wic.bmp');
for I := 1 to 50 do
begin
fn := 'D:\test'+IntToStr(Random(10000))+'.tif';
ImageEnMView1.MIO.SaveToFileTIFF( fn );
end;
Posted - Oct 25 2020 : 07:37:28 I made a quite simple test with some buttons, each to save the TImageEnMView bitmaps in a different format (TIF, JPG).
After opening the app and loading a few bitmaps in TImageEnMView, saving one or more of them as TIF fails. If then (with the same app still open, therefore the same hardware conditions) I save the bitmaps as JPG (works correctly) and retry to save them as TIF, the TIF saving succeeds. It seems as if saving a single bitmap as JPG corrects something. In fact, if TImageEnMView contains only one bitmap, TIF saving works correctly right from the start.
Al
xequte
Posted - Oct 25 2020 : 01:11:55 Hi Al
Sounds like some kind of drive caching issue. Does it only happen on a particular drive? What about when you test on an external hard drive?