PDA

Click to See Complete Forum and Search --> : Resizing a jpg


MHengst
Aug 9th, 2000, 04:00 AM
Does anyone have any code examples that can resize a jpg? I want to be able to make thumbnails automaticaly instead of having to do it using a seperate program. I played with a intel dll a while back that lets you save a jpg but couldn't get it to do what i wanted.

kedaman
Aug 9th, 2000, 08:17 AM
You should use paintpicture to resize your picture

object.PaintPicture picture, x1, y1, width1, height1, x2, y2, width2, height2, vbsrccopy

Just specify the object you want to paint to, the picture is the source picture property of a image or picturebox, and the coordinates and size parameters

kedaman
Aug 9th, 2000, 04:22 PM
You just have to save it back to the jpg, but that's another problem, i think there's code for that somewhere, try search for it

Aug 9th, 2000, 04:46 PM
VB cannot save in JPEG format. If you change the file extention to .JPG, it will save, but the format will still be a Bitmap, not a JPEG.

kedaman
Aug 9th, 2000, 05:46 PM
I know that, i only said that there's code somewhere to save for it, btw i found it on my own harddisk, shall send it?

MHengst
Aug 9th, 2000, 06:29 PM
could you send it to mhengst@hotmail.com? Thanks. Intel has a dll or something avalible to save jpgs, used to have it, is that what this is?

kedaman
Aug 10th, 2000, 03:20 PM
ACtually It's source, not sure where i got it, possibly planet source code.
sent.