Welcome Guest! To enable all features, please Login or Register.



Last Go to last post Unread Go to first unread post
#1 Posted : Tuesday, February 21, 2017 9:02:02 AM(UTC)

Chris F  
Chris F

Groups: Registered
Posts: 1

Currently I am using Lead Tools 17.4 to load a mult-page tif image into the viewer. The tif is 93 MB in size, 24 BPP and is 41 pages. I am using the following code to load the image into the viewer:

var codecs = new RasterCodecs();
CodecsImageInfo info = codecs.GetInformation(tempSourceFilePath, true);
var image = codecs.Load(tempSourceFilePath, 0, CodecsLoadByteOrder.BgrOrGray, 1, info.TotalPages);

rivImage.Image = image;

In the codecs information (info) I see a total number of pages is equal to 41. However, when it attempts to the load the file into an image, I will get anywhere from 30 - 35 pages loaded.

If there anything I can do to make sure that the image fully gets loaded?

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

#2 Posted : Friday, February 24, 2017 11:32:28 AM(UTC)


Groups: Tech Support
Posts: 366

Thanks: 1 times
Was thanked: 4 time(s) in 4 post(s)


You didn't post the size of each page here. Assuming each page is a typical 8" x 11.5" sheet of paper @ 300 DPI, each page will consume about 23.6 MB. For 41 pages, you would need to use approximately 968 MB just for those bitmaps. I suspect you may be running out of [contiguous] memory here. The number of pages actually loaded will vary based on the memory that can be used by the application at that time.

Is there a reason you would need to load all 41 pages into the application at one time? You wouldn't be able to display all of those pages at the same time to be displayed. I would expect there must be some other reason at play here.

Is a 41-page document the biggest document you'll need to load, or will you need to load larger document than that?

One possibility might be using the 64-bit binaries if you aren't already, but regardless of which set of binaries you use, there will be an upper limit to the memory that can be used.
Walter Bates
Senior Support Engineer
LEAD Technologies, Inc.
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2023, Yet Another Forum.NET
This page was generated in 0.361 seconds.