BigB
October 29, 2019, 9:15am
1
Hi everybody,
I’m struggeling for a few days now on a “part/divion line” problem.
I found a lot of content in forum to create parts, but I would do the opposite workflow.
How to extract geometry of a sketch division line ?
Is this even possible ?
Or extract geometry of divisions ?
I came up with this, to me it’s a dead end…
Many thanks !
Dude go here.
you may a get anything that may be helpful.
@jostein_olsen Thank you, I do not have a nice blog like your self, and I thought I might share a little something while trying to learn for my self.
##How to make this work for multiple walls?
A limitation with the above python script is that it will only work for a single wall element, and that is not very efficient. We have two options to make it work for a list of walls:
Wrap the python script in a custom node, be sure to define the input correctly as explained by @Dimitar_Venkov in t…
BigB
October 29, 2019, 10:12am
3
Thanks, I’ve been already read this post, but not sure what I’m missing or supposed to specifically see.
Can you be more specific ?
I’m not so confident with python, trying to understand the more I can !
Is something related to this code in the post you mentionned ?
##Code for getting location line
import clr
clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
clr.AddReference('RevitNodes')
import Revit
clr.ImportExtensions(Revit.GeometryConversion)
def ProcessList(_func, _list):
return map( lambda x: ProcessList(_func, x) if type(x)==list else _func(x), _list )
def UnwrapAndGetLocation(item):
return UnwrapElement(item).Location.Curve.ToProtoType(True)
OUT = ProcessList(UnwrapAndGetLocation, IN[0])
Not sure how to use this…