View Full Version : sourcing mel in internet
02-14-2009, 07:57 AM
I know this can sound crazy but I think is worth giving it a try
I been thinking for some time, is Maya capable to source a script that is not in the hard drive not even in your local network but in the web?
so I place a dum script in http://www.vitattoo.741.com/p.mel it is a test one it will just print A
so i give it a try and as you gess i fail miserably :(.......
If any one have an idea how this can be done, will be most appreciated
02-14-2009, 11:43 AM
I think you could use python to download the file and save it as a .mel script in your scripts folder. Then make maya source the file and just run the script. Then when it's done make maya or python, or anything else delete the file.
All you actually need is:
Downloading the file to scripts folder
Source the file (couldn't be that hard I guess?)
Run the script
Delete the file.
This way you 'redownload' the file everytime you run it. Which would make it somewhat slow, depending on the size of the file. Your download speed and the server speed. It could be 'saved temporarily' for a certain time so if you run it five times after eachother you only download it once. But then if you run it after each other, the script doesn't get redownloaded even if it's updated while you were 'trying to source it from the internet'
You could make an UI that force updates it, thus redownloads it.
Instead of making a temporarily file, you could make python say: "Download 'internet' sourced files'. Thus overwriting old versions, and so updating with new. Instead of downloading it everytime.
What was your concept? How did you think about bringing this into practice?
I think you could source it straight from the internet, but that would 'actually' redownload the file each time, set it into memory, run it. Redownload, set in memory, run it. If i'm not mistaking. This could be a 'slower' way.
Oh yeah, I also don't know how to do it. Just got interested and try to share some ideas on this.
02-16-2009, 11:42 AM
I've seen Joojaa on the highend3d API forum do this. Can't for the life of me find the post though. IIRC, he just used command port to set up a html server from inside maya.
02-16-2009, 11:42 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2013, Jelsoft Enterprises Ltd.