MitMeshPoly

From DreamsteepWiki

Jump to: navigation, search
			itMeshPoly = OpenMaya.MItMeshPolygon( obj )
			while not itMeshPoly.isDone() :
					#poly = OpenMaya.MPoly( )#OpenMaya.MSpace.kWorld
					CURPOLY = itMeshPoly.currentItem()
					NUMVERTSFACE = itMeshPoly.polygonVertexCount()
					vbuffer = ''
					itMeshPoly.vertexIndex(0)
					vbuffer = (' '+str(NUMVERTSFACE)+' < ')
					for a in ( range(NUMVERTSFACE) ):
								vbuffer=vbuffer+( str(itMeshPoly.vertexIndex(a) )+' '  )
								a=a+1
					vbuffer=vbuffer+'\n'
					#POLYINDECIES= vbuffer
					 # #
					TEXTDATA.append(vbuffer)
					itMeshPoly.next();
Personal tools