def FILL(h): doc =helper.getCurrentScene() box = doc.get_selection()[0] bb=helper.getCornerPointCube(box) h.buildGrid(boundingBox=bb) h.fill3(seedNum=0) execfile(plgDir+'/extension/testAF/c_displayFill.py')
def FILL(h): doc = helper.getCurrentScene() box = doc.get_selection()[0] bb = helper.getCornerPointCube(box) h.buildGrid(boundingBox=bb) h.fill3(seedNum=0) execfile(plgDir + '/extension/testAF/c_displayFill.py')
## len(h1.successfullJitter) ## t1 = time() ## h1.fill3(seedNum=3.40) ## print 'time to fill', time()-t1 ## h1.printFillInfo() ## execfile('displayFill.py') ## t1 = time() ## h1.fill3(seedNum=43420) ## print 'time to fill', time()-t1 ## h1.printFillInfo() ## execfile('displayFill.py') from Pmv.hostappInterface.cinema4d import helperC4D as helper #display the organel, the box, and prepare the hierachy... doc = helper.getCurrentScene() sel = doc.get_selection() c4dorganlle = sel[0] helper.triangulate(c4dorganlle) faces = c4dorganlle.get_polygons() c4dvertices = c4dorganlle.get_points() vertices = map(helper.vc4d,c4dvertices) vnormals = helper.GetFaces(c4dorganlle) o1 = Organelle(vertices, faces, vnormals) h1.addOrganelle(o1) o1.setSurfaceRecipe(rSurf1) # add padding bb = h1.boundingBox
## len(h1.successfullJitter) ## t1 = time() ## h1.fill3(seedNum=3.40) ## print 'time to fill', time()-t1 ## h1.printFillInfo() ## execfile('displayFill.py') ## t1 = time() ## h1.fill3(seedNum=43420) ## print 'time to fill', time()-t1 ## h1.printFillInfo() ## execfile('displayFill.py') from Pmv.hostappInterface.cinema4d import helperC4D as helper #display the organel, the box, and prepare the hierachy... doc = helper.getCurrentScene() sel = doc.get_selection() c4dorganlle = sel[0] helper.triangulate(c4dorganlle) faces = c4dorganlle.get_polygons() c4dvertices = c4dorganlle.get_points() vertices = list(map(helper.vc4d, c4dvertices)) vnormals = helper.GetFaces(c4dorganlle) o1 = Organelle(vertices, faces, vnormals) h1.addOrganelle(o1) o1.setSurfaceRecipe(rSurf1) # add padding bb = h1.boundingBox
from DejaVu.Cylinders import Cylinders from DejaVu.Geom import Geom from DejaVu.IndexedPolygons import IndexedPolygons from DejaVu.Points import Points from DejaVu.glfLabels import GlfLabels from DejaVu.Polylines import Polylines elif ViewerType == 'c4d': import c4d #from Pmv.hostappInterface import pdb_c4d import Pmv.hostappInterface.cinema4d.helperC4D as pdb_c4d vi = pdb_c4d Box = pdb_c4d.box Geom = pdb_c4d.newEmpty IndexedPolygons = pdb_c4d.polygons Points = pdb_c4d.PointCloudObject sc = pdb_c4d.getCurrentScene() dejavumat = vi.createDejaVuColorMat() helper = pdb_c4d elif ViewerType == 'blender': import Blender from Pmv.hostappInterface import pdb_blender vi = pdb_blender Box = pdb_blender.box Geom = pdb_blender.newEmpty IndexedPolygons = pdb_blender.polygons sc = pdb_blender.getCurrentScene() Points = None #display fill box #fbb = Box('fillpBB',cornerPoints=bb,visible=1) #maybe /10. #vi.AddObject(fbb)
from DejaVu.Cylinders import Cylinders from DejaVu.Geom import Geom from DejaVu.IndexedPolygons import IndexedPolygons from DejaVu.Points import Points from DejaVu.glfLabels import GlfLabels from DejaVu.Polylines import Polylines elif ViewerType == 'c4d': import c4d #from Pmv.hostappInterface import pdb_c4d import Pmv.hostappInterface.cinema4d.helperC4D as pdb_c4d vi = pdb_c4d Box = pdb_c4d.box Geom = pdb_c4d.newEmpty IndexedPolygons = pdb_c4d.polygons Points = pdb_c4d.PointCloudObject sc=pdb_c4d.getCurrentScene() dejavumat = vi.createDejaVuColorMat() helper = pdb_c4d elif ViewerType == 'blender': import Blender from Pmv.hostappInterface import pdb_blender vi = pdb_blender Box = pdb_blender.box Geom = pdb_blender.newEmpty IndexedPolygons = pdb_blender.polygons sc=pdb_blender.getCurrentScene() Points =None #display fill box #fbb = Box('fillpBB',cornerPoints=bb,visible=1) #maybe /10. #vi.AddObject(fbb)