Declaration
function IECalcJpegStreamQuality(Stream: TStream): Integer;
Description
Estimates the quality that was used for saving a Jpeg file.
The returned value can then be used for the
JPEG_Quality property (to maintain a similar quality level).
Result will be -1 if an error is encountered, e.g. for a non-JPEG image.
ImageEnView1.LoadFromFile('C:\input.jpg');
// do image processing here...
ImageEnView1.IO.Params.JPEG_Quality := IECalcJpegFileQuality('C:\input.jpg');
ImageEnView1.IO.SaveToFile('D:\output.jpg');