Computer Science Canada Pic.New decoding |
Author: | RaPsCaLLioN [ Sun Feb 06, 2005 1:14 pm ] |
Post subject: | Pic.New decoding |
Does anybody know how Pic.New saves an image as an integer? Example: I save a 50x50 bitmap image w/ 3 colours to a variable (using Pic.New). When I output that variable (put iObject) it puts "7003". Can anybody decode this? |
Author: | Delos [ Sun Feb 06, 2005 2:36 pm ] |
Post subject: | |
Your integer there is nothing more than a stream number. It's not a real integer (sic.) Now, as for streams...that's a different matter. |
Author: | RaPsCaLLioN [ Mon Feb 07, 2005 12:18 am ] |
Post subject: | |
please elaborate... |
Author: | Delos [ Mon Feb 07, 2005 10:10 am ] | ||
Post subject: | |||
Ok...try this:
On my comp, I got the int 7001. You may get something different. Now...in the editor window, click Run -> Show Debugger Menu Debugger -> Show Allocated Objects Then run again. You will notice in your Allocated Objects window 4 items...the first three being OOT windows (long story behind those too...had many a bad day dealing w/ those bloody -ve numbers), and a "Picture". As you can see, its ID is quoted as 7001, and it also has a location. I might be wrong about this, but it appears that the ID gives OOT a reference of where to look to find the pic/file to store in memory. Perhaps someone else can confirm...wtd? |