Jump to content
Sign in to follow this  
zaren

Mantra loop rendering

Recommended Posts

Hi all!

It is possible to render in loop?

For example I wrote some post render script which start mantra again. But I got warning - Recursion in parm callback.

This is Mantra1/postrender script:

i = hou.parm("/obj/control/num").eval()
i+= 1
if i < 10: 
    hou.parm("/obj/control/num").set(i)
    hou.parm("/out/Mantra1/execute").pressButton()

/obj/control/num is for to switch geometry. I want to switch geometry and render it. In this case I have 10 : /obj/geometry0 ... /obj/geometry10

If I press button Render - Mantra1 start once.

Script executed successes but last string. It seems merely ignored.

After render first frame script is started but without continue.

Thanx,

Sergiy

Edited by zaren
  • Like 1

Share this post


Link to post
Share on other sites

Hi all!

It is possible to render in loop?

For example I wrote some post render script which start mantra again. But I got warning - Recursion in parm callback.

This is Mantra1/postrender script:

i = hou.parm("/obj/control/num").eval()
i+= 1
if i < 10: 
    hou.parm("/obj/control/num").set(i)
    hou.parm("/out/Mantra1/execute").pressButton()

/obj/control/num is for to switch geometry. I want to switch geometry and render it. In this case I have 10 : /obj/geometry0 ... /obj/geometry10

If I press button Render - Mantra1 start once.

Script executed successes but last string. It seems merely ignored.

After render first frame script is started but without continue.

Thanx,

Take a look at the wedge ROP, it renders a ROP node n-times and can update parameters for each itteration.

There is a old video about it on the sidefx.com tutorials pages.

Edited by mawi

Share this post


Link to post
Share on other sites

Bump. Wedge ROP is not good enough for what I need. I'm building out a whole custom ROP loop node set, like the For Loop in SOPs. But every way I try to get a parm to re-execute a button's callback script, I get the "Recursion in parm callback" error. Which is annoying, because I know there's a recursion in the parm callback. That's exactly what I want lol. Is there any way around this?

EDIT: I suppose one way would be the Shell ROP, but I'd rather do it all through Python than having extra nodes laying around in my ROP loop.

Thanks,

 

~Chris

Edited by Shalinar

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×