Attach Topography to Floor

Hi Everyone. My first post - but have made extensive use of this forum thus far.

What is the best solution to attach underlying Topography to a floor (representing a road).
I’ve used the script mentioned here: http://dynamobim.org/forums/topic/attach-topography-to-rooffloorrampmodeletc/
TopographyToFace_jn.dyn (8.8 KB)

But it does not work for curving geometries - as it creates a grid.

I require it to follow the edges of the road - perhaps with an offset from the road?
See my attached WIP script so far. Help Appreciated!

TopographyToFloor_jn.dyn (4.9 KB)

TopographyToRoad_Dynamo_jn_Stripped.rvt (960 KB)

2 Likes

@Johannes_Nel Could you upload a stripped down version of your Revit model to try running this script on, or an image showing the geometry you are working with? Hard to help figure out the issue with just the .dyn!

Hi @awilliams. I have uploaded the .rvt file in my post above. It’s the topo on the ‘right’ which I am trying to have follow the floor hovering above it:

So youbare trying to pull the contour lines into the flat surface, or trying to fill the topography to create a ‘thickened’ floor that touches the face of the topography?

Hi @jacob.small. I’m trying to ‘fill’ the topography up to a selected floor/face. Such as done in this plugin:
https://apps.autodesk.com/RVT/en/Detail/Index?id=6806590222492123819&appLang=en&os=Win64

I recon the steps should be to add two sets of topography points - along the edges of the floor and along an offset on the selected topography.

@Johannes_Nel I’m not on a computer with Dynamo/Revit right now to experiment but I’m inclined to think that you could use the OOTB node Select Face (found in this list of Revit OOTB nodes: http://dictionary.dynamobim.com/#/Revit/Selection/Action/ ) and select the bottom face of the floor, then input that into an Element.Geometry node to get the curves. Then input that into PointAtEqualSegmentLength (http://dictionary.dynamobim.com/#/Geometry/Curve/Action/PointsAtEqualSegmentLength) to produce points along those curves. Those points could be added to your topo points rather than the Grid node in the script you referenced from a previous thread. Give that a try and see if it works; I will try and have a look when I have Dynamo, Revit, and enough time available, unless someone is able to help you out sooner :slight_smile:

Thank you @awilliams. I will give that a try and let you know.

@awilliams Following your suggestion I managed to get the curves selected and divided - and then to generate new topo points at those points. The next iteration will be to offset the curves from the floor and add those points to the existing topo surface. Have a look:

TopographyToFace_jn.dyn (11.7 KB)

The Points on the topography should be controlable as well.

1 Like

In this situation, I would probably try to project the road with an offset onto a flat plane below the topography, create a solid from both faces and then intersect the geometries, see this for instance:

2 Likes

Thank you @Yna_Db. I’ll take some time to figure out how to do that. Thanks for the suggestion

This is where I am. Can’t seem to get the Topo to split and produce points where the offset extrusion cuts it, YET!

TopographyToRoad_Dynamo_jn_Stripped.rvt (1.1 MB)

Topography_Split_CreateNewPoints_AttachToFace_jn.dyn (14.9 KB)

Just had a look at your latest graph - you’re close!

Notice that you are feeding a surface into the Surface.ByPatch node that you’re inputting into the Topography.IntersectionWithPlane node. No need for the Surface.ByPatch node as you already have a surface - you need to give the Topography.IntersectionWithPlane node a plane input :slightly_smiling_face: This thread should help:

@awilliams is right, be careful to match inputs and outputs types.
Topography.PolySurface (Zhukoven) and Geometry.Intersect nodes could also be useful in this process…

@Johannes_Nel See if this works for you
Topography-1.dyn (12.8 KB)


Topography-1.rvt (1012 KB)
Topography-1

1 Like

Obtained the below result with the same definition as above by splitting the topography up to the extent of the desired offset …
Topography-2.rvt (492 KB)

Topography-2

BTW, a non-Dynamo way to do it is to make 3D splines where you want the edges of topo to be in a Mass family, export to DWG, divide the splines with 2’ long line Blocks on a different layer, import the DWG back in and do topo by imported instance.

So, yay for Dynamo.

2 Likes

Other material available:

1 Like

That video verily expanded my mind. Hence, I wrote this AutoLISP to divide the lines in AutoCAD so all the
the endpoints can become topo points in Revit.

;Measure all lines by block "dl"
(defun c:dvall	(/ e i n s x)
  (if (setq s (ssget "x" '((0 . "LINE,SPLINE,ELLIPSE,POLYLINE,ARC"))))
    (progn (command "-insert" "dl=" ^c ^c)
	   (setq i 0
		 n (sslength s))
	   (repeat n
	     (setq e (ssname s i)
		   x (cdr (assoc 0 (entget e)))
		   i (1+ i))
	     (command "measure" e "b" "dl" "" "6")
;;;                (print i)
	     )))
  (princ))

dl.dwg (45.5 KB)

2 Likes

Thanks, that will be useful! :slightly_smiling_face:

Hi @Vikram_Subbaiah Thank you for the advise. As I understand you manually split the topography before running the script? Good workaround! I would like to incorporate the splitting of the surface by a defined offset into the script - in the future.

1 Like