Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #only proportionizes in the x direction so far
- # proportionize means to increase subdivisions such that there is approximately one
- # subdiv per scale factor which is currently the height of the object
- whichOne= plg.ls(selection = True)[0]
- active = plg.polyEvaluate(whichOne, boundingBox = True)
- sizeX = active[0][1] - active[0][0]
- sizeY = active[1][1] - active[1][0]
- sizeZ = active[2][1] - active[2][0]
- XoverY = float(sizeX/sizeY)
- howMuch = float(howMuch)
- if XoverY > howMuch:
- print 'true'
- plg.polyCube(whichOne, e=True, sx = int(sizeX/sizeY))
- else:
- print 'false'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement