- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I've recently started playing around with the MEL script capabilities in Maya, and have come across a small issue. The tutorial I have been following is out a book — Parametric Building Design With Maya.
He is importing an image, which he then maps the placement of the "Buildings" on a plane. That being said, I cannot link the image I have because I cannot locate the file itself.
string $filenode = `createNode file`;
string $shader = `createNode lambert`;
string $path = "C:/TM/topo-house16.TIF";
This is the first three lines of code. However the $path variable is using the "C" drive, for a Windows Machine. I own a Mac.
So essentially, it should link in a similar manner (or I think so).
On a mac it should look something like so: string $path ="/Users/username/Desktop/topo-house16.TIF";
The script runs fine, but in the console, it is logged that the file could not be found. Just to make sure, I executed the same file route on my mac with the "Goto folder" window. (Command + Shift + G). Typed in the same
Typed in the same file route, and located the image I was looking for. So it verified that the route was working, but from Maya, I could not load the image.
I am new to MEL and Python but have been modeling/animating with Maya for 4 years now. This is not my first time using a scripting language, however, unless I have to grab assets from specific folders within the MEL, I'm not sure where to go from here.
Thanks!
Solved! Go to Solution.
