Hello,
this is my code so far…
import sys
import clr
import System
from System.Collections.Generic import List
clr.AddReference('ProtoGeometry')
from Autodesk.DesignScript.Geometry import *
clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
import Autodesk.Revit.DB as DB
from Autodesk.Revit.DB.Structure import *
clr.AddReference('RevitNodes')
import Revit
clr.ImportExtensions(Revit.GeometryConversion)
clr.AddReference('RevitServices')
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
doc = DocumentManager.Instance.CurrentDBDocument
uidoc=DocumentManager.Instance.CurrentUIApplication.ActiveUIDocument
collector = FilteredElementCollector(doc).OfCategory(BuiltInCategory.OST_Roofs)
all_roofs = collector.WhereElementIsNotElementType().ToElements()
lst_Geo = []
opt = Options()
for i in all_roofs:
geoset = i.get_Geometry(opt)
for geo in geoset:
if isinstance(geo, DB.Solid):
lst_Geo.append(geo)
elif isinstance(geo, DB.GeometryInstance):
for geoi in geo.GetInstanceGeometry():
if isinstance(geoi, DB.Solid):
lst_Geo.append(geoi)
edges = [g.Edges for g in lst_Geo]
edge = [e for e in edges]
OUT = edges, edge
it worked pretty well, but it is listing any edge how can i get the perimeter edges?
here is a costum node hardcoded from Rhythm @john_pierson
have i to access the path for getting the edges (perimeter)
KR
Andreas