Site Survey to 3D mesh?
-
The Situation: I learned to do a site survey! I have 15 data points, with distance, height, and degree (from the survey level tripod thing). This was just of a random tiny area on my campus, to practice before I actually go to my build site and get a lot more points. With this data, which is on real paper (you know, written in ink pen on tree fiber) how can I then model the site such that I can show the hills and such, and model my proposed building? Can I somehow import a point cloud (I may be using that term wrong) into Sketchup (14.0.4899) and drape a sandbox thing over them?
My Ideal End: I type up the data in a spreadsheet like interface (three columns: distance, height, deg), import this data to Sketchup, which makes a landscape model from the data, and smooths out the curves. From this, I would like to be able to put in some 3D trees, drape a road onto it, and be able to "excavate" my build site and import my building model.
What I have tried: I have done about 3 hours of research into trying to do this, with no avail. I've seen people importing stuff from CAD, working off contour lines (which is a step ahead of what I have), or using Cloud_v8.0bx.rbz (which I could not get to run, likely because I am not using 2013.
My current lame solution: from the origin, draw a line the specified length, draw a second the specified height, select both lines, use the rotate tool to the specified degree, delete the length line. I end up with a bunch of vertical lines, I'll try seeing if I can push/pull a sandbox manually to the top of each line, if not I will manually draw triangles between each point. LAME! Also, I cannot imagine doing this with 200 points
I am sure people must do this, home builders, landscape architectures namely. If anyone can tell me how, I'd love it!
-
The Sandbox from Contours tool has a little secret: You don't need contour lines to use it, almost any 3D geometry will do. It should perform quite well with your small forest of vertical lines.
I used to get site surveys as 2D AutoCad DWG files with the surveyed points displayed as text objects with the surveyed height. To get that into SketchUp (it doesn't read AutoCad text) I wrote a small AutoLisp routine that did what you did - it added to every one of these texts a vertical line stretching to the surveyed height. Then I could import the file into SU and put a TIN on it with the From Contours tool.
Anssi
-
@Anssi, the sandbox from contours worked great! Snapped with to the top of each of my vertical line trees:)
STILL LOOKING FOR HELP! I would still love a less painful way to create geometry for the sandbox to snap to. @Anssi mentioned how they go about this, but I am unfamiliar with the programs they used (know some autoCAD, but cannot stand the mac version) so this seems inefficient for me. How do other people do this?
-
If you can put your 3D point coordinates into a text file, there are plugins that can import that into SketchUp as construction points and others that can form the surface automatically using these. Look for cloud.rb (its documentation will specify the exact format of the text file it understands). I haven't unfortunately used these myself.
Anssi
-
Cloud.rb works quite nicely. I have used this where a surveyor gave me an autocad file with just elevation points in it rather than contour lines. As Anssi says, if you can get your points in a text file, you will not need to make all the lines in Sketchup.
-
Have a look at my architecture plugins list and pay special attention to the land section.
http://sketchucation.com/forums/viewtopic.php?f=323%26amp;t=59471%26amp;p=541170#p541170
-
Still feeling confused, and still looking for an answer.
Let me rephrase. I have about 59 data points in 3D polar coordinates which I took with a dumpy level, survey stick, and tape measure. I have typed these into excel.
Example:
Length(m) Height(m) Angle(degrees)
5-----------3.00 ------28
2-----------0.53 ------228Note: the raw data is not corrected for declination, all the heights are inverse (If the level reads 3m, that means the depression is 3m below the level, so it is really -3m) and the height of the tripod is not accounted for (a reading of 0m is actually 0m+ the tripod height)
The Problem: How do I get this data into SU 2014, and create a sandbox from them? SOMEONE HAS TO HAVE DONE THIS BEFORE!
My currant approach:
- correct the polar coordinates in a new excel tab (CORRECTED DATA), i.e. add my declination to all the angels, multiply all heights by -1, then add the height of my instrument.
- Using the formulas
X coord=distance x SIN(angle)
Y coord= distance x COS(angle)I converted my polar coordinates to Cartesian coordinates (X,Y,Z,) and exported these as a .csv file.
3) Using "Point Gadget" (http://extensions.sketchup.com/en/content/point-gadget) I imported these points into SU2014. SU would not let me make a sandbox from contours, so I grouped the points, deleted all the geometry but the point (the program makes each point a little colored shape), exploded them, and THEN finally made my damn sandbox.Issue: Something went funny, and my conversion from polar to cartesian was not correct. The distance is off. I was using a formula based off of 2D. We were assuming that the D we should use in this equation is the adjacent angle (what I physically measures) but maybe the D needs to be the Hypotenuse? In which case I am lost.
People in real life do surveys of this kind, then model the ground. I am begging you, oh internet, to tell me how they do it FROM START TO FINISH, not just once I have a perfect .csv file of all the data in X,Y,Z, form.
-
@torrey said:
Still feeling confused, and still looking for an answer.
Let me rephrase. I have about 59 data points in 3D polar coordinates which I took with a dumpy level, survey stick, and tape measure. I have typed these into excel.
Example:
Length(m) Height(m) Angle(degrees)
5-----------3.00 ------28
2-----------0.53 ------228Note: the raw data is not corrected for declination, all the heights are inverse (If the level reads 3m, that means the depression is 3m below the level, so it is really -3m) and the height of the tripod is not accounted for (a reading of 0m is actually 0m+ the tripod height)
The Problem: How do I get this data into SU 2014, and create a sandbox from them? SOMEONE HAS TO HAVE DONE THIS BEFORE!
My currant approach:
- correct the polar coordinates in a new excel tab (CORRECTED DATA), i.e. add my declination to all the angels, multiply all heights by -1, then add the height of my instrument.
- Using the formulas
X coord=distance x SIN(angle)
Y coord= distance x COS(angle)I converted my polar coordinates to Cartesian coordinates (X,Y,Z,) and exported these as a .csv file.
3) Using "Point Gadget" (http://extensions.sketchup.com/en/content/point-gadget) I imported these points into SU2014. SU would not let me make a sandbox from contours, so I grouped the points, deleted all the geometry but the point (the program makes each point a little colored shape), exploded them, and THEN finally made my damn sandbox.Issue: Something went funny, and my conversion from polar to cartesian was not correct. The distance is off. I was using a formula based off of 2D. We were assuming that the D we should use in this equation is the adjacent angle (what I physically measures) but maybe the D needs to be the Hypotenuse? In which case I am lost.
People in real life do surveys of this kind, then model the ground. I am begging you, oh internet, to tell me how they do it FROM START TO FINISH, not just once I have a perfect .csv file of all the data in X,Y,Z, form.
Sandbox is never going to produce a surface from points. It only works with Edges. You will need Cloud or similar plugin to create the surface.
I assume the distance and angle are horizontal. How was the distance off? Obviously the slope distance will be different.
Here is a method that would allow you to input the data directly into SketchUp.
def radial_surveyor_key mod = Sketchup.active_model ent = mod.active_entities sel = mod.selection values = UI.inputbox([" Elev;"," H. I."," Dist;"," H. O.;"," Angle;"],[0.0.m,1.676.m,0.0.m,0.0.m,0.0],"Polar to XYZ") if values elev,hi,dist,ho,ang=values x=Math.sin(ang.degrees)*dist y=Math.cos(ang.degrees)*dist z=elev+hi-ho ent.add_cpoint(Geom;;Point3d.new(x,y,z)) end end
and this one will get the input from a .csv file.
def radial_surveyor_csv mod=Sketchup.active_model ent=mod.active_entities @csv_dir ||= "c;/users/public/temp/" @csv_file ||= "radial surveyor.csv" dots_file=UI.openpanel("File to Import from;", @csv_dir,@csv_file) if !dots_file then; return; end dots_input=File.open(dots_file); val=UI.inputbox(["Elev;"," H. I.;"],[0.0.m,1.5.m],"Radial Station Data") if !val then; return; end elev,hi=val while !dots_input.eof? dot = dots_input.readline d,h,a= dot.strip.split(",") dist=d.to_l;ho=h.to_l;ang=a.to_f x=Math.sin(ang.degrees)*dist y=Math.cos(ang.degrees)*dist z=elev+hi-ho ent.add_cpoint(Geom;;Point3d.new(x,y,z)) end dots_input.close end
-
Update: Realized the problem with my method: Excel uses radians, not degrees. Changed my data to radians, and everything worked smoothly. Project complete!
I will likely be doing this again in the future, so I'd love to figure a smoother way. @Sdmitch, could you give a quick run down how I run that code? I have never messed with code in SU before. Lets get a solid set of easily followed and accessible instructions for this problem down, as I found a lot of unanswered questions of this same problem in other forums.
-
@torrey said:
Update: Realized the problem with my method: Excel uses radians, not degrees. Changed my data to radians, and everything worked smoothly. Project complete!
I will likely be doing this again in the future, so I'd love to figure a smoother way. @Sdmitch, could you give a quick run down how I run that code? I have never messed with code in SU before. Lets get a solid set of easily followed and accessible instructions for this problem down, as I found a lot of unanswered questions of this same problem in other forums.
Will be glad to help anyway I can. I will incorporate the two methods into a plugin and send it to you by Private Message.
-
Fredo posted this today...
http://sketchucation.com/forums/viewtopic.php?f=323%26amp;t=60179
Advertisement