Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2004
    Location
    amsterdam
    Posts
    31

    Unanswered: Resizing problems with graphics in Pdox 10

    I have made an automatic import of graphic pictures in my database. The database imports the image in the undefined graphic field per record. The file name of the image is the content of the id-field. The pictures are in jpg format. Everything works (a bit slow over a network though), but the resolution of the pictures is too high for my graphic window. In the properties of the bitmap field there is a magnification tab. Where I can choose for 25% or ‘best fit’. This works as for the size, but the picture itself gets an improper look, false colors, red lines etc., probably caused by difficulties with resizing. When I resize the picture in Photo Editor or so (making it smaller), everything works fine. But this is a lot of work for 5000 photo’s.
    Anyone a solution?

  2. #2
    Join Date
    Aug 2003
    Location
    Bologna - Italy
    Posts
    209
    I don't understand well what you're trying to do.

    If you need to load images into a blob field in pdox, you have no need to memorize the file name, since you won't be using the file anymore, after the initial insertion.

    If you memorize the filename, that would mean that the file name would not change in time, so you should NOT load into a field the image, but instead use the file name to load at runtime the image file in a image control.

    Anyhow, if you need to resize the image to show it, you'd better have two versions of the image, one big and one small, rather than resize it every time you need; even if you only need a small version, it's a better idea to resize it before insertion in the db.

    You can mass-resize many images by using any of the batch image processing softwares you find on the net: ACDSee, XnView, and many others have such capabilities.

    Even with a small fragment of PHP code you can do that fast and simple.
    The only failure is not trying to do it.

  3. #3
    Join Date
    Jan 2004
    Location
    amsterdam
    Posts
    31
    Thank you for your advise. I don't use blob field, the database will become too large with more than 5000 pictures, indeed I load the graphic at runtime based on properties of the record (ever changing) as you suggested in your paragraph 2.

    Yes, I can mass-resize the graphics but why do so if Pdox itself has a resizing feature on the fly as I wrote. But this feature does not work properly, not in my database though, or does it?

    Does it?

  4. #4
    Join Date
    Aug 2003
    Location
    Bologna - Italy
    Posts
    209
    It's not made for quality: it's based merely on a windows bitmap resize, and so suffers of many defects.

    Have you tried working with .BMP instead of .JPG? I think this will solve the issue...

    Anyway, i'm suggesting again that you resize the images out of pdox; the only way pdox shows picture perfect bitmaps is if sizing is set to 100%.

    Bye!
    The only failure is not trying to do it.

  5. #5
    Join Date
    Jan 2004
    Location
    amsterdam
    Posts
    31
    No, BMP doesn't make any difference, nor BEST SIZE, nor 25% or 50% show acceptable images.

    Indeed, I have to resize the images outside Pdox. Thanks for your advice.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •