Toposurface : Elevation at a given point

I have a toposurface and a building pad,


and extracted building pad boundary. Now, I want to know the elevation of points projected upwards or downwards towards the toposurface from each vertex of the building pad boundary. Or, I want to project those vertices to the toposurface and get the coordinates of the resulting points. I tried so many ways but failed. The only one close to success was extracting the mesh from toposurface, convert to a surface, then project these points to get the desired list. But extracting the surface like this from toposurface is so ‘costly’ for big topo surfaces. I am sure there would be a better way. Could someone help? I have attached an image.

Inshort : How can we project certain 2d points to a toposurface?

This is quite easy to do by Selecting the Top face of the building pad you want to project and the topo on which you want to project. Results below



1 Like

Thanks for the solution @Joelmick … That would work for sure.

However, as I previously mentioned, wouldn’t that drastically affect the performance, to create polyface mesh for a complicated big toposurface? Or am I wrong…? Can we figure out a better and ‘low cost solution’ ?

What are the results do you get when you pull the geometry and the boundary curves of the building pad?

This would be a method to do it without the hard geometry calculations.

You can evaluate the XY coordinates of the corners of the buildingpad with the XY of the topo mesh. If you find the corresponding mesh vertices, you can have the projected points.

1 Like

OK, thankyou for your valuable time, @Joelmick

You will get the list of curves defining the face, if you pick the top face. If you go for Python Scripting within Dynamo, you may use the GetBoundary() method of BuildingPad class. That would get you a list of CurveLoop objects. You have to then iterate every item in it, using list comprehension in python, to convert them to curves that Dynamo could understand. For that you may use the ToProtoType() method. Something like;

OUT = [for c.ToProtoType() for c in buildingPadBoundary.GetCurveLoopIterator()]

So the flat, planar sketch which defines the limits of the pad, not the upper/lower bounds of the adjacent topo. You’ll want to pull the associated topography element instead, as that contains two meshes which are a bit easier to work with than the entire site. From there you can get the geometry, convert to a polysurface, and use topology to pull the edges which only have one adjacent face. The result:

This will contain two resulting loop sets: One for the building pad’s sketch lines, and one for the topography’s walls. For completely cut pads or completely filled pads these produce two loops, which can be grouped and filtered by height. For pads which are retaining on both sides things get messy as the curve loops overlap. You can simply filter out edges with the most common Z heights at both ends to remove the ‘pad edge’ from the set. This should get you one curve loop for the lines where the building meets the land, from which you can pull whatever points you’d desire.

1 Like

If you’re curious, this is a good starting PoC for the filtering out the topo pad curves:

Excellent… Thanks @jacob.small …!!
I will try this method. Intact I did not know that, that smaller portion of the topography could be extracted like that. Thanks again…

1 Like

Hi, I’m kind’a new to Dynamo so I think this solution looked smart. :slight_smile: Could I bother with asking U to share this dyn file?

Well if you are new, maybe it is a good exercise to copy the script off the image so you can see what happends node for node and get some feel for the nodes and methods used.

I didn’t save the graph since I don’t use building pads often :sweat_smile:
But the script is right there in image form

3 Likes

Sure, thanks anyway, I’ll give it a try. :wink:

This is why my comments were so verbose. :slight_smile: