Jump to content


Mantra loop rendering


  • Please log in to reply
2 replies to this topic

#1 zaren

zaren

    Peon

  • Members
  • Pip
  • 2 posts
  • Joined: 11-May 09
  • Name:Sergey Zar

Posted 07 July 2012 - 05:51 AM

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, 07 July 2012 - 06:00 AM.


#2 mawi

mawi

    Initiate

  • Members
  • PipPip
  • 170 posts
  • Joined: 26-May 08
  • Location:Stockholm / Sweden
  • Name:Martin W

Posted 07 July 2012 - 08:14 AM

View Postzaren, on 07 July 2012 - 05:51 AM, said:

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, 07 July 2012 - 11:57 AM.


#3 strages

strages

    Peon

  • Members
  • Pip
  • 22 posts
  • Joined: 19-October 11
  • Location:Netherlands
  • Name:Dimitrie Hoekstra

Posted 17 October 2012 - 07:23 AM

really nice to find this thing so easily, making use of this right now :)




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users