TiComponent.SaveImageToJPEG
TiComponent See Also
Saves the current image of the component to a JPEG bitmap file.
procedure SaveImageToJPEG(FileName: String; Compression: Integer; Progressive: Boolean);
Description
Use SaveImageToJPEGsave the current image of the component to a JPEG
compressed file. The JPEG is a lossy-compressed, pixel-based representation of the
component. It can be imported by many popular documentation and image editing
software (Such as Microsoft Office, Paint Shop Pro, PhotoShop, etc.) and displayed
on web pages.
Compression refers to the quality level of the compression you wish to apply
to the file. A quality of 100 will give a higher quality result than 33. Valid
values are between 0 and 100. With line art type graphics (like computer
screen shots and component images), it is recommended that you leave the
Compression value at 100 for the best results.
Progressive refers to the progressive encoding of the JPEG image file. When
this property is TRUE, then the image will be displayed progressively on a web
page as it is downloaded.
You can use this method to save out a JPEG image of the component for use in
ASP web pages where the component is instantiated and run on the server-side.
Example
Delphi
iComponent.SaveImageToJPEG('c:\temp\test.jpg', 100, True);
Kylix
iComponent.SaveImageToJPEG('/home/username/test', 100, True);
C++ Builder
iComponent->SaveImageToJPEG("c:\temp\test.jpg", 100, True);
Contents | Index | Previous | Next