ImageEn, unit imageenio




function LoadFromStreamWIC(Stream: TStream; FileFormat: TIOFileType = ioUnknown): Boolean;


Loads an image from a stream using TIEWICReader. The result will be false if an error is encountered, e.g. the file in the stream is not a compatible format (Aborting will be true).
Set FileFormat to use a specific decoder, otherwise use ioUnknown to automatically select a decoder.

- Some WIC formats require installation of a codec from the Microsoft store
- See WIC_Load_FileTypes for a list of WIC supported file types
- You can abort loading by setting Aborting to true
- LoadFromStreamWIC does not reset the position of the stream, so you may need to first call Stream.Position := 0;


// Load a raw camera file using WIC
ImageEnView1.IO.LoadFromStreamWIC( fs, ioRAW );

See Also

- LoadFromFileWIC
- SaveToStreamWIC
- WIC_Load_FileTypes
- WIC_FileTypes