Declaration
property StreamHeaders: Boolean;
Description
If True, each SaveToStreamXXX method adds an additional special header as needed for multi-image streams.
When a special header is added, the images saved with SaveToStream*** aren't compatible with LoadFromFile*** methods.
Note: Supported only by TIFF and JPEG at this time (let us know if you need other formats)
Default: False
Example
// Save ImageEnView1 and ImageEnView2 images in the file, images.dat
// Note: images.dat won't be loadable with LoadFromFileXXX methods
var
fs: TFileStream;
begin
fs := TFileStream.Create( 'D:\bmpimages.dat', fmCreate );
ImageEnView1.IO.StreamHeaders := True;
ImageEnView1.IO.SaveToStreamJPEG( fs );
ImageEnView2.IO.StreamHeaders := True;
ImageEnView2.IO.SaveToStreamJPEG( fs );
fs.Free();
end;
// Save a single image to image.jpg
// image.jpg is loadable with LoadFromFileXXX methods
var
fs: TFileStream;
begin
fs := TFileStream.Create( 'D:\image.jpg' );
ImageEnView1.IO.StreamHeaders := False;
ImageEnView1.IO.SaveToStreamJPEG( fs );
fs.Free();
end;