Using multiple UV sets in Maya

I can’t believe I have been missing out on this useful technique all this while.

This is most useful when you are using a Layered Texture (e.g. to plug into the color node of your MR / Vray shader), and would like the texture file nodes of each layer to be affected by a different UV layout.

Here’s a tutorial by Parker Davidson on Lesterbanks (a place for great 3D resources!) that gives a good explanation of how to use mutiple UV sets together with the layered texture.

http://lesterbanks.com/2013/10/using-mayas-layered-shader-and-multiple-uv-sets-to-facilitate-texture-detail/

In summary, to create mulitple UV sets for a single object,

– Go to the UV texture editor, under the Polygons menu > Copy UVs to UV set > Copy into New UV set (or just create an empty UV set)

– Name your UV sets, and you can switch among them under the UV Sets menu

– You can freely edit the UVs of each set or reapply certain UV mappings without affecting the other sets.

To link a texture file node to a specific UV set:

– Go to Relationship Editor > UV Linking > Texture-Centric

– Select the file node on the left, select the corresponding UV set you would like to use on the right

How is this useful?

Imagine that you are adding in details to a just a small corner of your object. Your texture resolution has to be really big in order for the details to be sharp. However, if you use a layered texture to add in the details to your base color / texture, by using multiple UV sets, you can scale up one of them without affecting the rest and thus use a much smaller texture resolution. You can now also have the freedom to move the details around by shifting the UVs in its UV set.

 

 

C4D Mograph Animation to Maya

Cinema 4D’s mograph tools are really powerful, and I was looking at its rigid body simulation capabilities (using the mograph tools) which seems like a very good alternative to Maya’s native rigid body dynamics, which can be slow to calculate or produce some crazy results when you are trying to simulate a large group of objects at one go.

Thus I was researching on ways to bring C4D’s mograph animation into Maya, and I was pleasantly surprised to find that it can be done really easily with the new alembic format support in C4D R14. All you need to do is to export your mograph cloner in the Alembic format in C4D, and then from Maya’s Animation menu, go to Pipeline Cache > Alembic Cache > Import Alemic, select your file and you are done!

If you wish to have further control in Maya, such as the ability to modify the keyframes of each cloned object (for effects such as bullet time or simply to move or hide a particular clone), one method will be to bake the mograph animation in C4D first before exporting it in the Alembic format.

Here’s a useful tutorial I’ve found on how to bake your mograph animation in C4D: http://www.youtube.com/watch?gl=SG&hl=en-GB&v=b-CnSGjkp68. It also shows the process of setting up a rigid body fracture animation using mograph, then baking the animation so that you will have editable keyframes for each individual cloner.

After you import the Alembic file into Maya, bake animation for all the objects and you will have editable keyframes in Maya too!

This method of baking animation in C4D is more of a work-around and thus it does seem a little inefficient. I would be happy if anyone can share a better method to do so :)

 

 

Maya Particles Random Rotation

I wrote a post about giving some random rotation to maya particles previously … and this is another method I’ve found that is more straightforward (useful when you are rushing for time and doesn’t need that much of control).

This is from a youtube tutorial by Stuart Christensen who learnt it from Eric Keller (http://www.youtube.com/watch?v=aGy0BqExwaI)

1) After setting up your emitter and particle instancer, go into the particleShape node ‘Per Particle (Array) Attributes’. Add a new ‘General’ Attribute (name it RotateMe for e.g,). Make sure the Data Type is ‘Vector‘ and Attribute Type is ‘Per particle (array)‘.

2) Add a new ‘creation expression':

float $rotRand=rand(180);
particleShape1.rotateMe=<<$rotRand,$rotRand,$rotRand>>;

(This expression gives your particles a random starting orientation)

3) Add a ‘runtime before dynamics’ expression:

particleShape1.rotateMe +=5

(This expression gives your particles a rotation value as you play the simulation. Adjust the numerical value to control the particles rotation speed accordingly.)

__________________________________________________________

And to add on, if you want your particles to stop rotating as they rest onto a surface, edit the ‘runtime before dynamics’ expression to something like this:

float $addRot=particleShape1.velocity/2;
particleShape1.rotateMe +=$addRot;

(With this expression, when the particles stop on a surface, their velocity will decrease to zero and thus, the rotation will stop too. Again, adjust the numerical value to control the particles rotation speed.)

Final Gather Flicker

Watched a Digital-Tutors tutorial on flicker-free final gather recently and one tip that left the deepest impression in me is that using luminescence planes to illuminate your scene is one major cause of final gather flicker (i.e. Using a polygon plane with a surface material or a material with incandescence to provide indirect illumination to your scene through final gather).

It was quite a big shock as many tutorials love to use these luminescence planes to demonstrate the effect of final gather, so I’ve never knew that such lighting setups are really prone to flickering.

And coincidentally I encountered such a scene a few days after. With the use of luminescence planes, there was persistent flickering even after I increased my FG accuracy to 1000, point density to 2, and point interpolation to 30 (it’s possible to go higher with these values still but it was really increasing my render times). After changing my lighting setup to use maya lights instead, the flickering almost entirely disappeared with just an FG accuracy of 300, point density of 1, and point interpolation of 10.

If you would like to maintain the reflections cast by your luminescence planes, you can still use the planes, but uncheck ‘Final Gather Cast’ & ‘Final Gather Receive’ under the mental ray tab of its shape node.

My friend also gave me some tips that could be helpful – increasing the ‘Filter‘ value under the final gather quality tab to 1 (helps to average out your final gather results), and changing the final gather mode under the final gather tracing tab to ‘Optimize for Animation‘.

And lastly, a tip also from digital tutors – Increase accuracy when you have blotchiness in the open areas where there isn’t really any geometry, and increase point density when you notice flickering on/underneath your geometry esp. at where the contact shadows are.

 

Final Gather flicker is such a big headache …

 

 

Vray Proxy (in Maya) Tips

Was researching a little about Vray Proxies a while back and found some tips regarding its use. Decided to document them here before I forget them all.

  • Before creating the proxies, make sure your geometry is final and also set up all the shaders needed.
  • Make a duplicate of your geometry as backup.
  • Combine all the geometry into 1 mesh. Delete history and freeze transformation.
  • Select your object, go to the menu Create|VRay|Create Proxy. Set up the path, filename, faces in preview, and make sure  “Automatically create proxies” option is checked.
  • Your object is now a vray proxy, and it has a “vraymeshmtl” node to which all its materials are connected to.
  • Select the proxy node in your outliner, export selected as a .ma/.mb file.
  • When you need to use the proxy, import the .ma/.mb file into your scene. (This is to ensure that your proxy doesn’t loses its vraymeshmtl node and thus it’s materials)
  • Duplicate your proxy as instancers if you need multiple copies (do not import it again as that means maya will have to load and read the proxy vrmesh file for all copies instead of just 1)

-

-