Geometry.py 文件源码

python
阅读 29 收藏 0 点赞 0 评论 0

项目:Simple-User-Input-Sculpture-Generation 作者: ClaireKincaid 项目源码 文件源码
def render_scad(self, filename = 'test.scad'):
        """Automatically renders an openscad file to an STL. 
        Still slightly WIP,
        as we're not completely sure on how to make shell-esque commands
        safe.

        TODO: Sanitize inputs, remove waiting (find a better solution)

        Inputs:
        filename: the file to open
        """
        output_name = filename.split('.')[0] + '.stl'

        proc = subprocess32.Popen(['openscad','-o',output_name,filename])
        print "Rendering..."
        proc.wait()
        proc.terminate()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号