cwisbg

timeLaps_takePic_v1

Dec 15th, 2012
223
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.58 KB | None | 0 0
  1. # timeLaps.py
  2. # Script to take the picture
  3. # Place in ~/Documents/
  4. # cwisbg.com
  5. from pymel.core import *
  6. import shutil as s
  7. import os
  8. def takePicture(fileNumber):
  9.     fileName = "timeLaps" + fileNumber
  10.     rotate("rotate_grp", 0,1,0,os=1,r=1)
  11.     tmpDirectory = (os.path.expanduser("~/Documents/maya/projects/default/images/tmp/timeLaps.iff"))
  12.     filePath = (os.path.expanduser("~/Desktop/productionFarm_projects/timeLaps/"+fileName+".iff"))    
  13.     hwRender(cam="camera1", cf=1, fnp = 1, d=1)
  14.     s.copy2(tmpDirectory, filePath)
  15.     print "picture taken", fileName + ".iff"
Advertisement
Add Comment
Please, Sign In to add comment