Maya 2016 Realflow Batch rendering not incrementing frame.

Discussions about the use of Realflow in Autodesk Maya
Prax
Posts: 1
Joined: Fri Jun 24, 2016 7:56 am

Maya 2016 Realflow Batch rendering not incrementing frame.

Postby Prax » Fri Jun 24, 2016 8:43 am

I have a simulation that does not increment the frame when batch rendering a realflow mesher object using Maya 2016 + Mental Ray.

What happens is that the scene animation works fine, however the realflow mesh does not increment/update beyond the start frame. The mesh is still on each frame while the rest of the scene moves along.

I know there is a bug in Maya 2016 that causes this very issue with plugins such as Mental Ray.

RFConnect comes supplied with a script that works around the issue by injecting rfrk5TimeAttrHack2016 into "Pre render frame MEL" in render settings. Its duty is to update the time attribute to the current frame.

Excerpt from the script:
// Maya 2016 has a bug which prevents connected attributes from evaluating properly if they belong to a plug-in node (mental ray, in this case).
// Therefore, we must go through all our nodes before each frame is rendered and force the time attribute to the current frame.

Function from the script (rfrk5Common.mel -> rfrk5TimeAttrHack2016):

Code: Select all

global proc rfrk5TimeAttrHack2016()
{
    // Maya 2016 has a bug which prevents connected attributes from evaluating properly if they belong to a plug-in node (mental ray, in this case).
    // Therefore, we must go through all our nodes before each frame is rendered and force the time attribute to the current frame.
    int $frame = `currentTime -q`;
    string $types[] = { "openvdb_rk_mesh5", "openvdb_hybrido_mesh5", "rk_mesh5", "hybrido_mesh5", "rfrk_particler5", "rfrk_cloud5" };
    for($type in $types)
    {
      string $nodes[] = `ls -type $type`;
      for($node in $nodes)
      {
        setAttr ($node + ".frame") $frame;
      }
    }
}

Logs do not show any errors. It appears that this function is only triggered once at render start, but does not trigger/update per frame as it is supposed to do; or maybe I'm simply missing a checkbox somewhere in the expanse of checkboxes. What I do know is that the frame and time seem decoupled when dealing with Mental Ray related nodes.

Any help would be appreciated.


Return to “Autodesk Maya”

Who is online

Users browsing this forum: No registered users and 2 guests