Welcome to WebmasterWorld Guest from 54.205.20.160

Forum Moderators: coopster & jatar k

Message Too Old, No Replies

What would affect imagecopy()?

   
2:45 pm on May 29, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I've created a function that's part of a class of image functions. The function in question replaces 'tiles' from a $source image on to a $dest image according to some $x, $y and $dimensions (it's a square so height and width are the same).

The weird thing is that if I run this function on one script, it runs fine. However, if I run the function on another script - bare in mind they're both getting the same variables - the output is different.

So what could affect imagecopy()?

4:56 pm on May 29, 2008 (gmt 0)

WebmasterWorld Senior Member eelixduppy is a WebmasterWorld Top Contributor of All Time 5+ Year Member



Just for clarification, you are using the same $source, $dest, $x, $y, and $dimension values for both scripts and getting different output? What is the difference in output?
6:02 pm on May 29, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Yep. The difference is that scriptA draws the write amount of 'tiles', whereas scriptB displays one randomly placed 'tile' (note: the location doesn't change on reload, it stays in the same place)
3:58 pm on Jun 3, 2008 (gmt 0)

WebmasterWorld Senior Member eelixduppy is a WebmasterWorld Top Contributor of All Time 5+ Year Member



Have you sorted this yet? I cannot imagine what would make different images if the exact same data was passed to the function just the function is within different scripts on the same server. My guess is there is something small that you are overlooking. I also have a feeling that the input to the functions are slightly different giving you different output. there's something wrong with the logic somewhere it seems.
4:03 pm on Jun 3, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



It's really weird. I've resorted to disabling the function in scriptB and only allowing it to be rebuild in scriptA. Weird...
 

Featured Threads

Hot Threads This Week

Hot Threads This Month