Dexie Posted October 9, 2007 Share Posted October 9, 2007 I have a digital topographic survey in 2D which has spot heights in meters but with no Z value. Is there a script available to read the value of each spot height, and insert a 3D locus at the insertion point of the text object with the correct Z value. I am using Landmark. I don't really want to insert them manually and give them a Z value. Quote Link to comment
Petri Posted October 9, 2007 Share Posted October 9, 2007 If you can't find freeware, ask your distributor to ask Ultirender. There is such a script in the Finnish localisation. Quote Link to comment
Vectorworks, Inc Employee Robert Anderson Posted October 9, 2007 Vectorworks, Inc Employee Share Posted October 9, 2007 Have you tried the "Import Survey File..." command? Quote Link to comment
Petri Posted October 9, 2007 Share Posted October 9, 2007 Does that do the trick? Never realised... Quote Link to comment
Dexie Posted October 9, 2007 Author Share Posted October 9, 2007 No that doesn't work there is no external survey data. The data for the 3D loci is just in a number of text box in the drawing itself. Quote Link to comment
Vectorworks, Inc Employee Robert Anderson Posted October 9, 2007 Vectorworks, Inc Employee Share Posted October 9, 2007 Are they 3D loci, located at the proper points in space, or 2D loci with a Z value in text? Quote Link to comment
Vectorworks, Inc Employee Robert Anderson Posted October 9, 2007 Vectorworks, Inc Employee Share Posted October 9, 2007 Are they 3D loci, located at the proper points in space, or 2D loci with a Z value in text? Or something else (two crossed lines)? Quote Link to comment
islandmon Posted October 9, 2007 Share Posted October 9, 2007 Dexie, making the transition from static to dynamic requires direct access to the original data ... either from the CAD programmer , the Surveyor, or in the worst case... someone ...probably you... copying out the text and pasting into a tab delimited XYZ txt format . Then VW can use the "Import Survey' script to import the XYZ ( or YXZ, northing-easting-elevation ) into a DTM Layer for you to manipulate in 3d. Quote Link to comment
Petri Posted October 9, 2007 Share Posted October 9, 2007 A generic DTM data generation script - as the one mentioned above - may also fail if the programmer has not anticipated the notation used. Surveyors are a suprisingly imaginative group of people! A particularly nasty and practically impossible notation is one where there is a cross and two separate text items, like full metres on the left, decimal part on the right. Quote Link to comment
ccroft Posted October 10, 2007 Share Posted October 10, 2007 My reading of this is that we have a 2d plan view with some sort of text object centered on the correct x/y coordinates, and the Z info contained in the text. Dexie: Is my understanding of your file correct, and is there anything else in the text objects other than the Z value? So if somebody had the time, they might make a script that stepped thru each text object, recorded it's X&Y in the drawing, read the Z number from that object and wrote all that to a delimited file which then could be read by Inport Survey. An automation of what imon mentioned. Might be easier than scripting that plus the drawing part. If I wasn't so mired in trouble-shooting a couple of my ancient scripts I might give it a go. Best of luck Charles Quote Link to comment
Dexie Posted October 10, 2007 Author Share Posted October 10, 2007 That exactly right. The Z heigth is depicted in text and the xy coordinate is at the text box insertion box. A script to perform the repetative task would be an idea work around. If anyone has the time or unlike me the knowledge. The thing I like about this forum is that people are so helpful an there is always someone who comes up with a solution on another way of approaching a problem. Quote Link to comment
dspearman Posted October 10, 2007 Share Posted October 10, 2007 this vectorscript will do what you want but I will caution you .. it ain't pretty PROCEDURE Example; FUNCTION text2stake(h :HANDLE) :BOOLEAN;VAR???r, g, b :LONGINT; p1X, p1Y, p2X, p2Y ,p2Z:REAL; NewStake:HANDLE; Objtext:STRING; BEGIN if GetType(h)=10 then begin Objtext:=GetText(h); p2z:=Str2Num(Objtext); GetBBox(h,p1X, p1Y, p2X, p2Y ); NewStake:=CreateCustomObjectN('Stake Object',p2x,p2y,0,False); SetRField(NewStake,'Stake Object','Mode', 'Include as site model data'); SetRField(NewStake,'Stake Object','Style', 'Triangle'); SetRField(NewStake,'Stake Object','Scale Factor', '1'); Move3DObj(NewStake,0,0,p2z); END; END;??? BEGIN??? ForEachObjectInLayer(text2stake, 2, 0, 0); END; RUN(Example); Quote Link to comment
Dexie Posted October 12, 2007 Author Share Posted October 12, 2007 I will give this a try. Thanks for spending the time to help. Many thanks. Quote Link to comment
Yancka Posted January 19, 2010 Share Posted January 19, 2010 Thanks dspearman, I've got same problem as Dexie and your script (with slight modifications) did the trick! I was trying to create worksheet with DB row displaying X, Y values (via =XCENTER, =YCENTER, before that I had to adjust text alignment properties to center/center) but were out of any luck finding how to get that text content to be shown for Z value. After I would have exported worksheet and imported as survey data. I didn't know the site model can be made from objects other (stake) than mentioned in help (Import Survey File, 2D Polys to 3D Contours, 3D Polys to 3D Loci (Landmark only), and Grid Method Entry). What else was weird that I found this thread using google with "text z value site:techboard.nemetschek.net" query, because local searching engine has limitations for minimal text length. NNA - improve your search engine, please! Quote Link to comment
Diamond Posted September 16, 2013 Share Posted September 16, 2013 This is an old post, but it just made my life a whole lot easier with an old ongoing project. Thank you dsspearman. Quote Link to comment
Recommended Posts
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.