i'm brand new in using the GdPicture.Net and now testing Thumbnail control and GdViewer control (in the document viewer sample).
I would like to use the controls for viewing big PDF files (180 MBytes, 5000 pages).
In those cases memory consumption is an important point.
So i'm testing both controls about memory consumption.
Win XP Prof. SP3 32 Bit, VS2005, VB.net
Test 1:
When i open the PDF in the viewer sample the process needs about 60 Mbytes RAM and loads first page very quickly into GdViewer control.
![Smile :-)](./images/smilies/icon_smile.gif)
When i go to diffent pages using the bookmark list it needs a little more memory.
![Smile :-)](./images/smilies/icon_smile.gif)
But if i use the mouse wheel (set to "page change") to jump to next pages it needs more and more memory for each page.
![Sad :-(](./images/smilies/icon_sad.gif)
It seems that GdViewer1 control doesn't free allocated memory for the previous page when processing page change events.
Is there a bug ?
2. Test
Setting ThumbnailEx1.PauseThumbsLoading = False causes the ThumbnailEx control to create thumbs of all 5000 PDF pages in a background thread. Of course it allocates memory for every thumbnail.
Just having 50 pages ... that's no problem. Having 5000 pages could be risky !
So i stopped the document viewer creating thumbs at a memory consumtion of 850 MBytes
before my virtual machine crashes !!!
![Sad :-(](./images/smilies/icon_sad.gif)
Is there a way to configure ThumbnailEx that it only creates thumbs for a predefined page range
instead of creating automatically thumbs for all document pages ?
Or better creates thumbs for a page range related to the scrollbar position ?
f.e. it could work like a fixed frame or window that walks through the documents pages every time the ThumbnailEx scroll position changes. Then it dynamically creates thumbs for the pages related to the current scroll position considering the ThumbnailEx thumbs layout. Maybe for better scrolling performance it could keep the last 10 thumbs (releted to the current scroll position) in memory and preload next 10 thumbs in the background.