Created
January 11, 2017 16:48
-
-
Save greenvfx/e4e9245bb1f277d3cf7d5b63fa6b4e43 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import subprocess | |
import os | |
import glob | |
import sys | |
a = r"C:\\Program Files\\Side Effects Software\\Houdini 15.0.244.16\\bin\\mantra.exe" | |
folder = sys.argv[1] | |
start = int(sys.argv[2]) | |
finish = int(sys.argv[3]) | |
for file in glob.glob(os.path.join(folder, "*.ifd")): | |
nameFileExt = os.path.basename(file) | |
nameFile = os.path.splitext(nameFileExt)[0] | |
frame = int(nameFile.split('.')[-1]) # | |
if frame <= finish and frame >= start: | |
print frame | |
cmd = [] | |
cmd.append(a) | |
cmd.append('-V') | |
cmd.append('2a') | |
cmd.append('-f') | |
cmd.append(file) | |
subprocess.Popen(cmd).wait() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment