add linux support
This commit is contained in:
parent
ad47faf960
commit
2224b23c71
1 changed files with 13 additions and 0 deletions
|
@ -200,6 +200,10 @@ def enqueue_job(event):
|
||||||
run(r'C:/Program\ Files/Blender\ Foundation/Blender\ 2.92/blender.exe --background {comp} --use-extension 1 --threads 0 --render-output {locationpath} --render-anim',
|
run(r'C:/Program\ Files/Blender\ Foundation/Blender\ 2.92/blender.exe --background {comp} --use-extension 1 --threads 0 --render-output {locationpath} --render-anim',
|
||||||
comp=work_comp,
|
comp=work_comp,
|
||||||
locationpath=intermediate_clip)
|
locationpath=intermediate_clip)
|
||||||
|
if platform.system() == 'Linux':
|
||||||
|
run(r'blender --background {comp} --use-extension 1 --threads 0 --render-output {locationpath} --render-anim',
|
||||||
|
comp=work_comp,
|
||||||
|
locationpath=intermediate_clip)
|
||||||
else:
|
else:
|
||||||
with open(args.project + 'intro.py', 'r') as fp:
|
with open(args.project + 'intro.py', 'r') as fp:
|
||||||
scriptstr = fp.read()
|
scriptstr = fp.read()
|
||||||
|
@ -212,6 +216,8 @@ def enqueue_job(event):
|
||||||
fp.write(scriptstr)
|
fp.write(scriptstr)
|
||||||
|
|
||||||
if platform.system() == 'Darwin':
|
if platform.system() == 'Darwin':
|
||||||
|
if args.debug:
|
||||||
|
print("running: Blender.app --background %s --python-use-system-env --python %s --use-extension 1 --threads 0 --render-output %s --render-anim" % (work_source, work_doc, intermediate_clip))
|
||||||
run(r'/Applications/Blender.app/Contents/MacOS/Blender --background {source} --python-use-system-env --python {jobpath} --use-extension 1 --threads 0 --render-output {locationpath} --render-anim',
|
run(r'/Applications/Blender.app/Contents/MacOS/Blender --background {source} --python-use-system-env --python {jobpath} --use-extension 1 --threads 0 --render-output {locationpath} --render-anim',
|
||||||
source=work_source,
|
source=work_source,
|
||||||
jobpath=work_doc,
|
jobpath=work_doc,
|
||||||
|
@ -224,6 +230,13 @@ def enqueue_job(event):
|
||||||
source=work_source,
|
source=work_source,
|
||||||
jobpath=work_doc,
|
jobpath=work_doc,
|
||||||
locationpath=intermediate_clip)
|
locationpath=intermediate_clip)
|
||||||
|
if platform.system() == 'Linux':
|
||||||
|
if args.debug:
|
||||||
|
print("running: blender --background %s --python-use-system-env --python %s --use-extension 1 --threads 0 --render-output %s --render-anim" % (work_source, work_doc, intermediate_clip))
|
||||||
|
run(r'blender --background {source} --python-use-system-env --python {jobpath} --use-extension 1 --threads 0 --render-output {locationpath} --render-anim',
|
||||||
|
source=work_source,
|
||||||
|
jobpath=work_doc,
|
||||||
|
locationpath=intermediate_clip)
|
||||||
if args.debug or args.keep:
|
if args.debug or args.keep:
|
||||||
copyfile(work_doc, args.project + event_id + '.py')
|
copyfile(work_doc, args.project + event_id + '.py')
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue