1-Introduction to Maya Projects

Maya Project is a folder that contains a workspace.mel file. It also includes some subfolders. All the files that are used in the Maya scene should be saved in the Maya Project folder and preferably in the related subfolders. For example, Maya scenes could be saved in the scenes folder, image textures in sourceimages folder, and so on.

When we define and set up a Maya Project, then we are able to move the whole project folder to another computer without being worried if the scene is gonna load correctly. It is specifically crucial to be able to transfer Maya files non-destructively when you want to render on another machine. Setting up a Maya Project is super easy and first step to submit a render job on a render farm. My advice is to set up a Maya Project and adhere to its structure as soon as you start working with Maya. So let’s see how to do it right from the beginning! But before that, Let's find out how Maya Projects work!

Figure 1-1. Default structure of a Maya Project: test_project

1-1-How Maya Projects Work:

So far, we have learned that Maya Project is a folder that contains workspace.mel file and enables us to move our Maya scenes from one computer to another without the scenes getting messed up. But how does Maya Project enables us to do that? Why can’t I just put everything in a folder and move it to another computer?
Let’s consider an example to find the answer to these questions. I created a sphere in a Maya scene and assigned a PxrSurface material to it. Then I connected an image, textureImageRed.jpg, to the color channel of the material in two different scenarios. First scenario(Figure1-2), without setting up a correct Maya Project, and second scenario after setting up a correct Maya Project(Figure1-3).

As you can see in Figure1-2, when I assign the image to the material before setting up the Maya Project, the path starts with the user folder on my computer and goes down each folder until it gets to textureImageRed.jpg. This path is an absolute path. This means that file structure of my local machine, starting from the User, is included in the path. As a result, if I move the whole Maya folder to another computer, this path is not valid anymore and it doesn’t lead Maya to textureImageRed.jpg.

Now, look at Figure1-2 in which I first set up my Maya Project to be test_project, then assign textureImageRed.jpg to the material. As you can see here, the path has changed! It doesn’t start with the User folder on my machine, it starts at the folder that contains the workspace.mel file which we know is our Maya Project folder, test_project. The path that is created this way, is a relative path. It considers the workspace.mel file as the beginning of the path and sees everything down the folder that contains this file.

Figure 1-3. An example of a path after setting up a Maya Project correctly.

Figure 1-3. An example of a path after setting up a Maya Project correctly.

In simple terms, creating and setting up a Maya Project enables us to tell Maya what to see when it saves the paths to external files. If we don’t maintain a Maya Project workflow, Maya sees everything regarding saving paths, and that causes problems when we transfer Maya files to another computer. But when we adhere to Maya Project rules, and set everything correctly, Maya only sees down our project folder, and this way, our file structure is independent of our computer’s file structure. As a result, when we move our Maya files, every path is still valid.

Figure 1-4. The path Maya sees when no Maya Project is set.

Figure 1-4. The path Maya sees when Maya Project is set.