Jump to content
  • 0
Hans-Olav

3d poly to 3d loci script?

Question

I have a file with 99 3d polys (circles) with right z height and are planning to do a DTM.

Anyone who can make a script to replace the 3d polys with a 3d loci in the centre of each?

Share this post


Link to post

6 answers to this question

Recommended Posts

  • 0

You could use the Replace with Symbol command. Replace it with a symbol that contains just a 3D locus. If you set it to convert to group on insertion then it will give you 99 loci which you just need to select and ungroup. Just tried it and it works fine

test done.vwx

  • Like 3

Share this post


Link to post
  • 0

In addition to Mark's suggestion - here's a Python script that will find all of the 3D polys on the active layer and replace their center point with a 3D locus.

 

My limited testing leads me to believe it works fine 😛 

 

lName = vs.GetLName(vs.ActLayer())
def createLoci(h):
	(p, zValue) = vs.Get3DCntr(h)
	vs.Locus3D(p, zValue)
	vs.DelObject(h)
vs.ForEachObject(createLoci, "((L='"+lName+"') & (T=POLY3D))")

 

  • Love 1

Share this post


Link to post
  • 0

Isn't the 3D Polys to 3d Loci command supposed to do this?  I've tried but that too fails.  see image for error

Screen Shot 2019-09-04 at 2.30.35 PM.png

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


 

7150 Riverwood Drive, Columbia, Maryland 21046, USA   |   Contact Us:   410-290-5114

 

© 2018 Vectorworks, Inc. All Rights Reserved. Vectorworks, Inc. is part of the Nemetschek Group.

×
×
  • Create New...