ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 ImageEnMView speed
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

chrisE

Germany
2 Posts

Posted - Dec 11 2018 :  15:32:03  Show Profile  Reply
Hi,

playing around with the demo version of ImageEnMView for a small project. Unfortunately, the speed seems to be pretty slow building the previews. Is there any way to use the embedded jpegs to speed it up as in the ImageEnView component? Or is this a limitation of the demo version?

Any help would be appreciated,
Chris

chrisE

Germany
2 Posts

Posted - Dec 11 2018 :  15:44:55  Show Profile  Reply
Damn, should have read the documentation more carefully. Found the options I was looking for, investigating...
Go to Top of Page

w2m

USA
1990 Posts

Posted - Dec 11 2018 :  15:55:48  Show Profile  Reply
You can try:
TImageEnMView.EnableImageCaching

Declaration

property EnableImageCaching: Boolean;

Description

Speeds up thumbnail painting by saving the view of each image to an internal cache. Set to false to disable image caching.

Default: False

See Also

- ClearImageCache
- ImageCacheSize
- ImageCacheUseDisk

Also:
TImageEnMView.EnableLoadEXIFThumbnails

Declaration

property EnableLoadEXIFThumbnails : Boolean
Description

Images from digital camera often contain a small thumbnail in their Exif data. When this option is enabled, ImageEn will use the EXIF thumbnail for display rather than loading and sub-sampling the full size image. This speeds up loading of large images.

Default: True

Notes:
- Has no effect if StoreType is ietNormal
- Will also set RAW_HalfSize and RAW_GetEmbeddedJpeg to true

Example

// Do not use EXIF thumbnails for digital camera images
ImageEnMView1.EnableLoadEXIFThumbnails := False;

Also:

TImageEnMView.WicFastLoading

Declaration

property WicFastLoading: boolean;

Description

Enables use of TIEWICReader for loading of JPEG and PNG files. This can greatly improve loading speed compared with native Delphi code.
Although WIC supports BMP, PNG, ICO, JPEG, GIF, TIFF and HDP, WicFastLoading is only used with JPEG (around 3 times faster) and PNG (around 30% faster), because it tends to be slower with TIFF and GIF, and provides no speed benefits with BMP and ICO. WicFastLoadingis best when you want a full size view of the image, do not need meta-data, and do not plan to save (or if saving, don't mind losing the meta-data).

Notes:
- If WicFastLoading is enabled, it will automatically use normal loading for unsupported formats
- JPEG meta-data (EXIF, IPTC, XMP, etc) will not be filled when using WicFastLoading (so will be lost if you save a WIC loaded image)
- WicFastLoading will not be used if any of the following are enabled: EnableLoadEXIFThumbnails, EnableLoadExplorerThumbnails or EnableAdjustOrientation

Example

// Faster filling of a TImageEnMView from a folder
ImageEnMView1.WicFastLoading := True;
ImageEnMView1.FillFromDirectory('D:\Images\');

Demo

Demos\Multi\MViewPerformance\Performance.dpr

Also:

TImageEnMView.LoadFromFileOnDemand

Declaration

procedure LoadFromFileOnDemand(const FileName: WideString; Append: Boolean = false);

Description

Fills TImageEnMView with all frames of a multiple image file (AVI, MPEG, TIFF, etc.) by filling ImageFileName with filenames and all indexes of its frames (in the format 'FileName::0', 'FileName::1', etc.).

In this way loading of individual frames will be delayed until they are required (i.e. frames are only loaded when they appear on-screen). It is mainly used for loading the frames of files with numerous frames (such as videos).

When Append is false, the existing content of the TImageEnMView is cleared.

Note: You can set TImageEnMView.MIO.Aborting := True to abort the loading of an OnDemand sequence

Example

ImageEnMView1.LoadFromFileOnDemand('C:\input.mpeg');

If input.mpeg has 1000 frames, then we will now have:
ImageEnMView1.ImageFileName[0] = 'C:\input.mpeg::0'
ImageEnMView1.ImageFileName[1] = 'C:\input.mpeg::1'
...
ImageEnMView1.ImageFileName[999] = 'C:\input.mpeg::999'

Demo

Demos\InputOutput\LargeVideos\LargeVideos.dpr

Bill Miller
Adirondack Software & Graphics
Email: w2m@hughes.net
EBook: http://www.imageen.com/ebook/
Custom Commercial ImageEn Development
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: