It is currently 18 Jun 2013, 08:04

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Python access to PointCloud & Mesh
PostPosted: 15 Jul 2012, 19:55 
Offline
User avatar

Joined: 06 Jun 2011, 16:00
Posts: 307
Any example code on how to access the Transform and other properties from each Point in a PointCloud via Python?

Also, some code to access Mesh data via Python?

Thanks

-TS-


Top
 Profile  
 
 Post subject: Re: Python access to PointCloud & Mesh
PostPosted: 15 Jul 2012, 22:26 
Offline
User avatar

Joined: 09 Jul 2012, 15:31
Posts: 108
Location: Granada, Spain
TwinSnakes007 wrote:
Any example code on how to access the Transform and other properties from each Point in a PointCloud via Python?

Code:
from siutils import si, log

oPCloud = si.Selection(0)
oGeo = oPCloud.ActivePrimitive.Geometry
lData = oGeo.ICEAttributes("PointPosition").DataArray
for i, oVector in enumerate(lData):
   log("ID: %d" % i)
   log("PointPosition: %s" % str(oVector.Get2()))
   log("---")


Quote:
Also, some code to access Mesh data via Python?

Code:
from siutils import si, log

oCube = si.Selection(0)
oGeo = oCube.ActivePrimitive.Geometry
lPoints = oGeo.Points
for i, oPoint in enumerate(lPoints):
   log("ID: %d" % i)
   log("PointPosition: %s" % str(oPoint.Position.Get2()))
   log("---")


http://download.autodesk.com/global/docs/softimage2013/en_us/sdkguide/si_om/Geometry.html ;)

* Added url tags around link - Eric T.

_________________
Image
Website


Top
 Profile  
 
 Post subject: Re: Python access to PointCloud & Mesh
PostPosted: 16 Jul 2012, 02:27 
Offline
User avatar

Joined: 06 Jun 2011, 16:00
Posts: 307
Thank you very much.

:D


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group