Houdini flipbook default output location

508 Views Asked by At

I would like to set a default output location for the Houdini flipbook so that all users have a standard path to save and look for their flipbook sequences rather than everyone inputting their own save locations from the gui. Is there an option or setting for that, preferably something I could set with an environment variable?

1

There are 1 best solutions below

0
On

This script might help. Just create a new tool and paste code into script tab. Once you click on the tool, it will load up the flipbook and save jpg sequence to disk. Also make sure to create "resx" and "resy" here, here, and here PS: double check if folder you are outputing JPGs to exists.

import os
import toolutils


filename = "---YOURPATH---/$HIPNAME/$HIPNAME.$F4.jpg"

scene = toolutils.sceneViewer()

setting = scene.flipbookSettings().stash()
res = (int(hou.getenv("resx")), int(hou.getenv("resy")))
range = hou.playbar.playbackRange()

setting.frameRange(range)
setting.output(filename)
setting.useResolution(True)
setting.motionBlurSegments(10)
setting.resolution(res) 
setting.useMotionBlur(False)

scene.flipbook(scene.curViewport(), settings)