Corridor Creation via 3D Mass or Adaptive Family Edges
Generate a parametric bridge corridor by picking a curve edge directly from any 3D Mass or Adaptive Family already placed in Revit — no Civil 3D, no DWG import needed.
What is the 3D Mass / Adaptive Method?
This is the third corridor creation method in AutoBRIDGE. Instead of reading data from Civil 3D or a linked DWG, it extracts individual curve edges — Lines and Arcs — directly from any 3D Mass or Adaptive Family instance already present in the active Revit document. The extracted edge becomes the alignment path that AutoBRIDGE sweeps a nested cross-section family along.
This method is ideal when the bridge geometry was conceived in Revit's massing environment, or when an existing adaptive family (such as a terrain surface, deck concept, or parametric form) already contains the desired alignment edge.
From Revit Mass Geometry
Reads Line and Arc edges directly from 3D Mass or Adaptive Family instances placed in the model — no external files required.
Click-to-Select Curve
A live 3D preview lets you click directly on the desired edge in the canvas to select it, or choose from the dropdown list of curve descriptions.
2D Cross-Section Validator
A separate preview panel shows the family edges by subcategory colour with boundary validation — confirming closed loops before you run.
Full Form Layout
The form is organised into five zones: a top combo bar (A) for source and curve selection, a full-width 3D preview canvas (B), then below that a family mapping panel (C) on the left and the chainages grid (D) on the right — both at equal width — and finally the run bar (E) at the bottom.
Select the 3D Mass or Adaptive Family
The first combo (comboBox1, placeholder text "3D Mass / Adaptive") lists every eligible element in the active Revit document — 3D Masses and Adaptive Component instances whose geometry contains extractable Line or Arc curves. Select the element that contains the edge you want to use as the corridor alignment.
Choose the Source Element
Open the left dropdown (Zone A). AutoBRIDGE scans the document and lists all 3D Masses and Adaptive Family instances. When you select one, the code immediately reads its full geometry, extracts all Line and Arc curve edges, and populates the second combo and the 3D preview canvas.
- The element must be a 3D Mass or an Adaptive Component already placed in the model.
- The element must have at least one Line or Arc edge in its geometry — nurbs or splines are not supported directly.
- Selecting triggers
comboBox1_SelectedIndexChangedwhich repopulatescomboBox2and refreshespictureBox2.
Pick the Alignment Curve Edge
After selecting the mass, all extractable edges appear in the second combo (comboBox2). Each entry describes one edge by its type and geometry. You pick the specific curve that will act as the centreline of the corridor.
Select the Curve from the Dropdown or Click in 3D Preview
The second combo lists every Line and Arc edge found in the mass geometry, described as:
Line: Start(X, Y, Z), End(X, Y, Z)— a straight edge.Arc: Center(X, Y, Z), Radius(R)— a curved arc edge.
You can select from this list or click directly on the desired edge in the 3D Preview canvas — the canvas selection syncs to the combo and vice versa. The selected curve highlights in cyan in the preview.
Reverse Direction (⇄ button)
The ⇄ toggle (checkBox4) reverses the direction of the selected curve's polyline. Because the corridor is swept from start to end along the curve, direction matters for chamfer alignment, skew, and subcategory placement. If the generated corridor appears to be oriented 180° from expectation, toggle this checkbox before running.
The Interactive 3D Preview Canvas
The large grey panel (pictureBox2) is a fully interactive 3D orthographic view of all curves extracted from the selected mass. It renders in real time as parameters change, showing the selected alignment curve with interval station markers.
Navigating and Reading the 3D Preview
The canvas draws all curves using a spherical camera projection (azimuth + elevation angles). The XYZ axis triad in the corner orients you. The currently selected curve is drawn in cyan, all others in grey.
Once chainages are entered, three types of markers appear on the selected curve:
- Cyan dots — Start station points (first point of each span)
- Yellow dots — Interval/frequency points (where adaptive instances will be placed)
- Red dots — End station points (last point of each span)
| Interaction | Control | Effect |
|---|---|---|
| Select a curve | Left-click on curve in canvas | Highlights curve in cyan; syncs comboBox2 selection. Threshold: 10 px proximity. |
| Rotate view | Ctrl + Left-drag | Adjusts azimuth (horizontal) and elevation (vertical) angles of the spherical camera. |
| Pan view | Middle-drag | Shifts panOffsetX / panOffsetY to translate the entire scene. |
| Zoom | Scroll wheel | Adjusts camera radius (distance from centre). Clamped to minimum 1. |
| Reset view | Double-click | Resets pan offsets to zero; restores fit radius. |
Select the Nested Family
The Corridors Nested Family combo (comboBox4) on the right panel selects the adaptive cross-section family that gets swept along the selected curve edge. This is the same nested family concept as in the other corridor methods.
Choose the Cross-Section Family
The combo is populated with all loaded corridor nested families (Revit families already in the project that are designated as corridor cross-sections). Select the family that represents the bridge cross-section shape to be swept — deck slab, box girder, I-beam arrangement, etc.
When a nested family is selected, comboBox4_SelectedIndexChanged triggers pictureBox3_Paint, which reads the family's edge geometry and renders the 2D cross-section preview below, colour-coded by subcategory.
Map Solid & Void Subcategories
The right panel contains two CheckedListBox controls — one for Solid subcategories and one for Void subcategories. These are populated automatically from the cross-section geometry when a nested family is selected. You assign each subcategory to either the Solid or Void group.
Assign Subcategories to Solid or Void
Every named subcategory found in the nested family's edge data appears in both lists initially. Checking an item in the Solid list automatically removes it from the Void list, and vice versa — they are mutually exclusive. The 2D cross-section preview uses the same colour coding as the lists.
- Solid subcategories — geometry that produces structural material in the corridor (slab, wall, girder faces).
- Void subcategories — geometry that cuts or removes material (internal hollow sections, openings).
If no subcategories are checked in either list, AutoBRIDGE will ask for confirmation before running — it will still generate the corridor but without solid/void distinction.
Define Chainages & Frequency
The Chainages DataGrid (dataGridView1) in Zone D defines how the corridor spans are distributed along the selected curve. It has five columns and works similarly to the other corridor methods — with advanced frequency mode options.
Enter Span Data — Station, Interval & Frequency
Each row defines one corridor span. Enter values in the editable columns; Span Length is calculated automatically. The active editable columns depend on the Corridor Settings type:
| Column | Editable? | Description |
|---|---|---|
StartStation | Yes | Corridor span start in metres along the curve. Automatically fills adjacent rows when End Station is entered (equal subdivision). |
EndStation | Yes | Corridor span end in metres. Entering a value triggers automatic distribution of intermediate rows. |
SpanLength | No (auto) | Calculated as EndStation − StartStation (with EJ offsets applied). Always read-only. |
IntervalSection | Settings 1–4 only | Spacing in metres between adaptive instances within the span. Editable when setting type is 1–4; auto-calculated when type is 5. |
FrequencyCounts | Settings 5 only | Number of adaptive instances per span. Editable only when setting type is 5; auto-calculated otherwise. |
EJ Offset (textBoxEJ)
The EJ Offset field applies an Expansion Joint inset at both ends of every span row. The value (in metres) is added to the Start Station and subtracted from the End Station before any calculations — effectively shortening each span by 2 × EJ to leave clearance at supports. Set to 0 for no offset.
Corridor Settings (⚙ Settings button)
The Settings button (setButton) opens the CorridorSettingsControl form — the same settings panel used by all corridor methods. It controls the Section Arrangement mode (Start, End, From Center, To Center) and which column (Interval or FrequencyCount) is the primary editable input. Changes to Settings update the DataGrid column read-only states immediately.
Run the Corridor
The RUN button (button4) validates all inputs and processes each span row in sequence. A progress bar and a row blink effect provide live feedback during generation.
Validation, Processing & Report
Before processing, AutoBRIDGE checks:
- Mass / Adaptive selected (
comboBox1) — error if nothing is selected. - Curve selected (
comboBox2) — error if no curve edge is chosen. - Nested family selected (
comboBox4) — error if no family is chosen. - At least one chainage row — error if the grid is empty.
- Station range check — rows where Start or End station falls outside the total curve length are flagged. A dialog asks whether to skip those rows or abort entirely.
For each valid row, AutoBRIDGE calls DoWorkA() which places adaptive cross-section instances at every station along the extracted curve, applying the EJ offset and subcategory solid/void assignments. Rows blink hot-pink during processing, turn blue on success and red on failure.
End-to-End Workflow
Place a 3D Mass or Adaptive Family in Revit
The element must already exist in the model with at least one extractable Line or Arc edge that represents the desired alignment path.
Open AutoBRIDGE → Corridor → 3D Mass / Adaptive
A corridor template must be selected in Settings first. The form opens and scans the document for eligible masses and adaptive families.
Select the source mass from comboBox1
The 3D preview canvas fills with the mass wireframe. All extractable curve edges are listed in comboBox2.
Pick the alignment curve edge
Click a curve in the 3D canvas, or choose from comboBox2. The selected curve highlights in cyan. Use the ⇄ toggle to reverse direction if needed.
Select the nested cross-section family (comboBox4)
The 2D section preview renders with subcategory colour coding and boundary validation status.
Assign Solid and Void subcategories
Check items in the Solid list for structural geometry; check items in the Void list for cuts/openings. Each item is mutually exclusive between the two lists.
Enter span chainages, interval and EJ offset
Fill the DataGrid rows with Start/End stations in metres. Set Interval spacing or Frequency Count (depending on Settings type). Enter EJ Offset if expansion joints need clearance.
Click RUN and review the report
AutoBRIDGE processes each row. Successful rows turn blue, failed rows turn red. A report dialog summarises the result count.
Three Corridor Methods — Comparison
| Feature | Civil 3D | 3D PolyLine | 3D Mass / Adaptive |
|---|---|---|---|
| Software required | Civil 3D open | Revit only | Revit only |
| Alignment source | Civil 3D Alignment + Profile | 3D PolyLine in linked DWG | Line / Arc edge from Revit mass geometry |
| Curve types supported | Any (via polyline tessellation) | Polyline segments | Line and Arc edges (tessellated) |
| Direction control | Alignment direction | Polyline vertex order | ⇄ toggle reverses polyline direction |
| Span definition | Manual or equal | Manual or Lines option | Manual entry in DataGrid |
| EJ Offset | — | — | ✓ textBoxEJ field |
| 3D interactive preview | Plan + Elevation views | Plan view | Full 3D rotatable view + 2D section preview |
| Subcategory mapping | Family tab | Family tab | Inline Solid/Void CheckedListBoxes |
| Output parameter | AutoBRIDGE_Type = "AutoBRIDGE_Corridor" on all instances | ||
Troubleshooting
| Symptom | Likely Cause | Fix |
|---|---|---|
| Form shows template warning and closes | No corridor template selected in Settings | Open Settings → Template tab and select a template, then re-open the form |
| comboBox1 is empty | No 3D Masses or Adaptive Families in the document | Place at least one 3D Mass or Adaptive Component in the Revit model before opening the form |
| comboBox2 is empty after selecting a mass | Mass geometry has no extractable Line or Arc edges | Check that the mass has solid geometry with distinct edges; Nurbs/splines are not extracted. Simplify the mass geometry. |
| 3D preview is blank | No curves were found in the selected element | Confirm the mass has geometry; try a different element. Check the error log. |
| Corridor is oriented opposite to expected | Curve polyline direction is reversed | Enable the ⇄ checkbox to reverse the polyline direction and re-run |
| Subcategory lists are empty | No named subcategories in the nested family's edge data | Confirm the nested family cross-section has geometry assigned to named subcategories in the family editor |
| 2D section preview shows ✗ boundary error | Some edges are not forming closed loops (dangling endpoints shown as red dots) | Return to the nested family editor and close all open boundary edges; confirm all outlines are closed polygons or loops |
| Rows turn red during run | Start/End station out of the curve's total length, or DoWorkA failed | Verify station values are within the curve length shown. Check that the nested family loads correctly. Review the report dialog for the specific failure message. |
| EJ Offset causes empty spans | EJ value is too large relative to span length | Reduce the EJ Offset so that Start + EJ < End − EJ for every row |