ImageEn, unit iexBitmaps

TIOParams.RAW_EmbeddedJpegLoading

TIOParams.RAW_EmbeddedJpegLoading


Declaration

property RAW_EmbeddedJpegLoading: TIERAWEmbeddedJpegLoading;


Description

Specifies the method that is used to load the embedded JPEG when RAW_GetEmbeddedJpeg = True.
Value Description
ierlDefault The embedded JPEG is loaded at the default size
ierlWIC Uses the TIEWICReader to load the JPEG at its default size
ierlScaled Loading of the embedded JPEG is speeded up by loading a scaled (smaller) version of the image (as with JPEG_Scale. The image is guaranteed to be no smaller than RAW_EmbeddedJpegMinWidth x RAW_EmbeddedJpegMinHeight

Generally ierlScaled will give the best performance.

Default: ierlDefault (Specified by IOParamDefaults)


Demos

Demo  Demos\InputOutput\CameraRaw\CameraRaw.dpr
Demo  Demos\InputOutput\IEViewPerformance\Performance.dpr


Raw Loading Speed

ImageEn offers four properties to improve loading speed for RAW images:
RAW_GetExifThumbnail
RAW_GetEmbeddedJpeg
RAW_EmbeddedJpegLoading
RAW_HalfSize


Performance Testing

// Testing loading of 100 raw images of various types:
IEGlobalSettings().CameraRawEngine := ieenDLL;
ImageEnView1.IO.Params.RAW_GetExifThumbnail      := loadExif;
ImageEnView1.IO.Params.RAW_GetEmbeddedJpeg       := loadJpeg or loadExif;
ImageEnView1.IO.Params.RAW_EmbeddedJpegLoading   := jpegMethod;
ImageEnView1.IO.Params.RAW_EmbeddedJpegMinWidth  := 200;
ImageEnView1.IO.Params.RAW_EmbeddedJpegMinHeight := 200;
ImageEnView1.IO.Params.RAW_HalfSize              := loadHalf or loadJpeg or loadExif;
t := GetTickCount;
for i := 0 to ss.Count - 1 do
  ImageEnView1.IO.LoadFromFile( ss[i] );
memo1.Lines.Add('Load: ' + FloatToStr( GetTickCount - t / 1000 ));

Load Method Load Method Time
RAW_GetExifThumbnail loadExif=True 1.6 ms
RAW_GetEmbeddedJpeg (Scaled) loadJpeg=True, jpegMethod=ierScaled 1.7 ms
RAW_GetEmbeddedJpeg (WIC) loadJpeg=True, jpegMethod=ierWIC 2.1 ms
RAW_GetEmbeddedJpeg (Default) loadJpeg=True, jpegMethod=ierDefault 2.9 ms
RAW_HalfSize loadHalf = True 8.6 ms
Normal - 19.4 ms


Example

// Fastest loading of a RAW image at no smaller than 800x600
ImageEnView1.IO.Params.RAW_GetEmbeddedJpeg       := True;
ImageEnView1.IO.Params.RAW_EmbeddedJpegMinWidth  := 800;
ImageEnView1.IO.Params.RAW_EmbeddedJpegMinHeight := 600;
ImageEnView1.IO.Params.RAW_EmbeddedJpegLoading   := ierlScaled;
ImageEnView1.IO.LoadFromFile('C:\CRW_0001.CRW');


See Also

OptimizeLoadingParams
RAW_EmbeddedJpegMinWidth
RAW_EmbeddedJpegMinHeight