1
0
mirror of https://github.com/nophead/Mendel90.git synced 2025-08-06 05:17:26 +02:00

auto renderer

This commit is contained in:
Simon Kirkby
2012-03-16 23:14:52 +08:00
parent aa42994a56
commit f8afc5987f
3 changed files with 69 additions and 3 deletions

View File

@@ -1,6 +1,7 @@
import os
import sys
import shutil
import commands
def render(machine):
render_dir = machine + os.sep + "render"
@@ -14,8 +15,8 @@ def render(machine):
for i in li:
stls.append(i[:-4])
for i in stls:
command = 'blender utils'+os.sep+'render.blend -P utils'+os.sep+'viz.py -- '+machine+os.sep+'stls'+os.sep+i+'.stl '+machine+os.sep+'render'+os.sep+i+'.png'
print command
command = 'blender -b utils'+os.sep+'render.blend -P utils'+os.sep+'viz.py -- '+machine+os.sep+'stls'+os.sep+i+'.stl '+machine+os.sep+'render'+os.sep+i+'.png'
print commands.getstatusoutput(command)[1]
if __name__ == '__main__':
if len(sys.argv) > 1: