← Back to team overview

yade-users team mailing list archive

Re: [Question #706976]: Reconstruct particles from ct images

 

Question #706976 on Yade changed:
https://answers.launchpad.net/yade/+question/706976

    Status: Open => Answered

Vasileios Angelidakis proposed the following answer:
Hi Kyle,

You can use something like:

c1 = ymport.text('yourClump.txt', shift=Vector3(0,0,0.5), scale=1.0, material='yourMaterial')
O.bodies.appendClumped(c1)

where yourClump.txt file should be in the format: x y z r, i.e. center and radius of each sphere, like here (for a three-sphere rod):
0 0 0 1
1 0 0 1
2 0 0 1

If you have all of your clump files in a the same directory, it should
be easy to iterate through them in a loop.

Hope this helps,
Vasileios

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.