Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

fast image loading

Status
Not open for further replies.

LaMancha

Technical User
May 23, 2003
20
US
hi, i am working on an image catalog program. i think LoadPicture function is very slow.
1. is there a faster way to load images?
2. can you advise me a way to load all images in a dir quickly ?

please be simple, i am quite new.
thanks
 
Yea I was wondering this, but my front-end processing takes so long it was not the highest priority. Is there an API? Seems a bit unlikely though, where do you put the image? (address etc)
 
I'm not entirely sure but you could try a few things.

Depending on how it is you are displaying your images you could try loading then in a web browser control (i'm not suer this is any faster).

Or you could use file streaming and stream the image to your form.

What control are you using to load the picture?


also check out these links


Transcend
[gorgeous]
 
hi, thanks for the responses.
I am not very sure about what control i am using exactly, i am using this algorithm:
i have a picturebox, named P e.g., then I load like:

P.Picture = LoadPicture( filename )

this is just basic way to do it I guess.
 
Then the control you are using is a picturebox :)

Try using an image control, see if that makes a difference

i think the syntax is something like image.picture = (filename)
The Image control uses fewer system resources and repaints faster than a PictureBox control, but it supports only a subset of the PictureBox properties, events, and methods.

Ah here we go, I just found this on a site:
Whenever possible, use Visual Basic's Image control instead of the PictureBox control. Both can display images, but the Image control displays much more quickly. Use the PictureBox control only when you need one of its special capabilities, such as dynamic data exchange (DDE), font properties or a special drawing method (such as .Line, .Circle or .PSet).

Transcend
[gorgeous]
 
thank you Transcend so much,
image definitely loads much faster.

i would like to hear if anybody has any tips-ideas to find all image files in a directory and make a database and photo album and such..

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top