ImageMagick using wrong file intermittently
Posted: 2010-10-26T16:53:36-07:00
I have a facility that lets people upload an image which is distorted over another image. It works fine - most of the time, and I have narrowed this down to form posts from Explorer (IE7 and IE8). The code is as follows;
/sw/bin/convert -virtual-pixel transparent \ \( "/.../virtualuploads/large/lg_Streetlights_900w.jpg" -size 900x600 \) \ \( "/.../temp/uploadedPic.jpg" -matte +distort Perspective \ '0,0 174,124 300,0 355,127 300,224 358,403 0,224 177,400' \) \ -layers merge +repage "/.../uploadedPic_insitu.png"
(Where '...' represents the true path which I've removed in this paste). The problem here is that in Explorer, ImageMagick sometimes turns up the right background (the file "lg_streetlights_900w.jpg" in the code above) and sometimes will select another from the same directory - even though the variable output on the page will show the filename that it should be.
Does anyone know why ImageMagick would randomly select another image/file when its being told specifically which one to use? ImageMagick version is 6.4.x (sorry, can't give exact) on Linux Ubuntu Server 9.04 (current patches etc) with Apache 2.2.14.
Thanks in advance.
/sw/bin/convert -virtual-pixel transparent \ \( "/.../virtualuploads/large/lg_Streetlights_900w.jpg" -size 900x600 \) \ \( "/.../temp/uploadedPic.jpg" -matte +distort Perspective \ '0,0 174,124 300,0 355,127 300,224 358,403 0,224 177,400' \) \ -layers merge +repage "/.../uploadedPic_insitu.png"
(Where '...' represents the true path which I've removed in this paste). The problem here is that in Explorer, ImageMagick sometimes turns up the right background (the file "lg_streetlights_900w.jpg" in the code above) and sometimes will select another from the same directory - even though the variable output on the page will show the filename that it should be.
Does anyone know why ImageMagick would randomly select another image/file when its being told specifically which one to use? ImageMagick version is 6.4.x (sorry, can't give exact) on Linux Ubuntu Server 9.04 (current patches etc) with Apache 2.2.14.
Thanks in advance.