Wednesday, May 12, 2010

Refreshing textures in Mental Ray

While this was not an issue with 2008, with our new 2010 versions of Maya it seems that it is needful to be more careful with where we are putting asset files such as textures etc.

One problem I ran into is that I was working on a texture (rendering, tweaking, rendering again) Mental Ray would keep rendering my old texture even after I had loaded it again in Hypershade. (The swatch would update but the render would not)

The way to solve this problem is to set your project to the current folder you are working under. In the case of our Virtual Chem Lab project, you would set the project to the main asset folder where everything is under.

Example 3D_Maya>Inorganic/Assets/Centrifuge_table (You would set the project to "Centrifuge_table."

From there, make sure your textures are located right underneath your "sourceimages" folder that Maya looks for. It will not work if you put it in any other folder. However, you can name the "sourceimages" folder whatever you want. I illustrated this below with screen grabs.

With our VCL pipeline, Rob created a folder called "Texture" in every asset main folder. It is fine to use this as the "sourceimages" folder, but it is important to type it in the "sourceImages" box exactly as it appears in the folder name. Problem solved! One more thing, the texture file needs to be directly inside this folder, it cannot be in a subfolder inside the folder, or it wont work. If organization is a big thing for you, I would recommend creating subfolders for each part of your asset, and then when the texture is final, bringing it back up directly under the "sourceimages" folder.