Revit API Forum
Welcome to Autodesk’s Revit API Forums. Share your knowledge, ask questions, and explore popular Revit API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SectionBox intersect with other elements

5 REPLIES 5
SOLVED
Reply
Message 1 of 6
Ning_Zhou
603 Views, 5 Replies

SectionBox intersect with other elements

is there a way to get intersection point between "4 edges" of SectionBox, and other elements, say a lined based family instance, or simply a model curve?

 

seems SectionBox don't have any geometry info., the only useful workaround is BoundingBoxXYZ, but again, how can you get "4 edges" of BoundingBoxXYZ?

 

any hint will be very much appreciated.

5 REPLIES 5
Message 2 of 6
Ning_Zhou
in reply to: Ning_Zhou

just find that section box on specific view cannot be retrieved correctly using the following code, if there're multiple 3D views w/ section box on:
List<Element> sbs = new FilteredElementCollector(doc, v3d.Id).OfCategory(BuiltInCategory.OST_Section).ToList();

seems that v3d.Id filter doesn't make any difference!? so how can you get specific section box on specific view?

i'm still using 2014.
Message 3 of 6
Ning_Zhou
in reply to: Ning_Zhou

well, seems section box can be directly retrieved from 3d view, overthinking again!
Message 4 of 6
Joe.Ye
in reply to: Ning_Zhou

 

Hi Ning,

 

BoundingBoxXYZ.Max and BoundingBoxXYZ.Min can return the maximum and minimum points coordinates of the box.

And then you can compose the 4 edges's curve from the above two coordinates.

 

 

 



Joe Ye
Contractor
Developer Technical Services
Autodesk Developer Network
Message 5 of 6
jeremytammik
in reply to: Ning_Zhou

Hi Ning,

 

Shall we consider this resolved for the moment, then?

 

Can you start a new thread if anything else crops up?

 

Thank you!

 

Cheers,

 

Jeremy



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

Message 6 of 6
Ning_Zhou
in reply to: Joe.Ye

thanks Joe, that's what i'm going to use for now even though i'm not quite sure the case of rotated section box.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Rail Community