me again :)…
I am converting dwg polylines into the Revit lines and I am getting huge amount of the lines. Very small ones.
With the script I am deleting every second line and I want the rest of lines to join into the closed loop.
Then this closed loop I can use for hatch or masking region. It’s detail lines inside detail family…
Just struggling with the joining part, tried many options but nothing…
Let me get this straight, you want to take adjacent pairs of the remaining lines and “extend to corner”? That won’t work well, you’ll run into issues for certain relative positions of the pairs of lines which you can’t reliably predict. Just get the starting point of each line, drop every 2nd one and join them. That way you’ll also be able to adjust the degree of simplification very easily, say just take every 5th point etc.
Hello @sovitek, thank you very much for your solution.
In this case I decided just to take a references from lines from dwg to create a new ones with your script. Founded more practical hen just copied them. I set the number of 150 total to be closer to the shape before. Everything works just perfect. It’s not too much diference in Mb from two Revit Detail Families but maybe overall when we are having too many inside the model makes the diference…
Thank you again both for your replies. Sorry, also to @jacob.small thanks to you…Didn’t see your post…
In atachment is the final script for everyone who wants to use it for their work…