Get Elements Hidden lines geometry

Get Elements Hidden lines geometry

nasirodin
Participant Participant
833 Views
3 Replies
Message 1 of 4

Get Elements Hidden lines geometry

nasirodin
Participant
Participant

Hi Everyone,

I'm trying to extract a list of geometries from a flex duct that partially obscured by another element. Query elements geometries using "element.get_Geometry()" method retrieves all lines including the hidden lines. 

is there any way to distinguish geometries related to the hidden lines?

 

Flex.png

 

 

Thanks for your help!

0 Likes
834 Views
3 Replies
Replies (3)
Message 2 of 4

jeremytammik
Autodesk
Autodesk

Check all the lines' GraphicsStyleId property:

 

https://www.revitapidocs.com/2020/4103f148-957e-3f44-9ccd-a5ed6702c689.htm

 



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

Message 3 of 4

nasirodin
Participant
Participant

Hi,

thanks for the reply,  unfortunately, all the lines' GraphicsStyleId property has the same value. even those lines obscured by the duct ( denoted in the following picture as hidden lines)

Flex.jpg

I'm querying geometries as follows, should I try different options?

 

var geometries = element.get_Geometry(new Options() { View = _document.ActiveView });

 

0 Likes
Message 4 of 4

jeremytammik
Autodesk
Autodesk

The only other option of interest that comes to mind is IncludeNonVisibleObjects:

 

https://www.revitapidocs.com/2020/0d277b80-d5e5-1151-d413-b0899da0976f.htm

 

However, that is apparently not required in this case...

 



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder