occasional image quality problems
ohthetrees
Joined: 2002-09-18
Posts: 20 |
![]() |
When I upload a whole folder of pics it works pretty well, but about 1 out of 30 to 40 pics will be corrupted. Usually the thumb, normal, and full sized version will all be corrupted in the same way. So far I have seen one with a red tinge, one that looked foggy white over two thirds of it, one that was blank on the bottom half, and one that was very dark on the bottom half. I imagine netpbm might be to blame, although I did use the binaries provided on this site. mac os 10.2 php info: http://aliandcedar.com:400/info.php thanks |
|
bharat
![]()
Joined: 2002-05-21
Posts: 7994 |
![]() |
If you re-upload the same image does it work? Gallery doesn't touch the original file, so if the original is corrupted then that's the way that Gallery received it... that implies that what you're seeing is a file transfer corruption issue (which is rare, but it happens). |
|
ohthetrees
Joined: 2002-09-18
Posts: 20 |
![]() |
if I re-upload, the picture turns out fine. However, the way I upload is to dump pictures into a staging directory on my webserver, then import using the url of the folder. So really gallery is uploading from the same site that it is running on. Where is the opportunity for corruption? If I look at the original (in the staging directory) it looks fine. The corruption happens between when I ask gallery to upload from a particular directory, and when it is posted. I have not noted any corruption on any pics when I upload them to my web server by other means. thanks for your help, cedar update: my copy of gallery seems to be doing more than just uploading the full sized version of the picture. It seems to be creating a version that is the same pixel dimensions as the original, but is jpeg optimized to a different (more compressed) level than the original. So I seem to be getting three sizes total, a thumb, a medium sized, and an original sized version that is compressed. Am I on crack, or is this really happening? |
|
bharat
![]()
Joined: 2002-05-21
Posts: 7994 |
![]() |
When you upload from the same server, are you using a URL or a direct filesystem path? Gallery invokes different PHP commands for those two situations. If it's a filesystem path, Gallery is using PHP's built-in copy() function to move the file. If it's a URL we do some slightly more complicated stuff. Either way, we're counting on PHP's system calls to get it right. I'd suggest that you upgrade PHP from 4.1.2 to 4.2.3, since I know they made some improvements in this code in the 4.2.x line. |
|
ohthetrees
Joined: 2002-09-18
Posts: 20 |
![]() |
I upload both ways, and experience corruption both ways. I'm looking into upgrading php. I'm not quite up to compiling it myself, but marc liyanage has binaries posted on his website. He notes this: Quote:
NOTE regarding 4.2.3: I had to remove support for the --enable-mbstr-enc-trans option because that caused POST variables to be cut off in certain circumstances. do I care about this? Should I upgrade to 4.2.3 despite this complication? An update to the corruption issue (it gets weirder). If I view my album using explorer pool1 and farm10 resized and farm16 full sized look corrupted |
|
bharat
![]()
Joined: 2002-05-21
Posts: 7994 |
![]() |
Quote:
If you experience this problem with my 4.2.3 module, please re-download the fixed version now or change your FORM tags in your HTML code to include this: Gallery 1.x does use this encoding type in the forms which upload image data, so Quote:
If I view my album using explorer pool1 and farm10 resized and farm16 full sized look corrupted If I view my album using mozilla, pool2 resized and pool10 full size look corrupted. That's odd. I just checked out pool1 resized, farm10 resized, farm 16 full using IE 6.0 and they looked fine to me. Are you sure you're not seeing a corrupted version of the image from your browser cache? |
|
ohthetrees
Joined: 2002-09-18
Posts: 20 |
![]() |
you are right, it was a cached version. I was right clicking and hitting reload image, but that doesn't seem to have been enough. I cleared the cache and restarted the browser and things looked ok. However, the original corruption problem was real. I made three changes that could have fixed it. One, I started uploading using a file path, rather than a web address (easily testable.), two, I recompliled netpbm to a more recent version, and three, I updated my php module. Anyway, it all works now. Yipee! |
|