MtoA post-translation callback stopped working

MtoA post-translation callback stopped working

arlon.swaders
Explorer Explorer
586 Views
1 Reply
Message 1 of 2

MtoA post-translation callback stopped working

arlon.swaders
Explorer
Explorer

Hi,

Recently we switched to MtoA 5 and noticed that our post-translation callback stopped working. Our callback is written in Python See this post for code example.

It seems that with the change of the Rendering API, the callback no longer has access to the current interactive render session's universe. When running the callback in MtoA 4, the node-iterator in the callback is able to find all nodes that were translated from the Maya scene. However, in MtoA 5 this seems to no longer be the case. Instead it seems to operate on a different universe, as it only iterates over the `root` node.

I already tried to get the default render session (as per the new API documentation), assuming the IPR render in Maya uses the default render session. However this seem not the case, as `AiGetSessionMode` tells me the session is not interactive.

>> session = AiRenderSession(None)  # Pass null pointer to get the default session.
>> print "Is interactive:", AiGetSessionMode(session) == AI_SESSION_INTERACTIVE
Is interactive: False


My question: Under the new render API, how would I get access to the active interactive render session and associated universe?

Any help would be greatly appreciated.

0 Likes
Accepted solutions (1)
587 Views
1 Reply
Reply (1)
Message 2 of 2

Stephen.Blair
Community Manager
Community Manager
Accepted solution

It's not currently possible to get the universe for a post-translation callback.

We have the ticket MTOA-966 open for this.

 

The default render session is basically a null, unused session.



// Stephen Blair
// Arnold Renderer Support
0 Likes