DynamoDS / Dynamo

Open Source Graphical Programming for Design
https://dynamobim.org
Other
1.67k stars 622 forks source link

Feature Request: Element Location node #1123

Closed andydandy74 closed 9 years ago

andydandy74 commented 10 years ago

The Family Instance Location node is a really useful tool. However, it does not work for elements like walls or lines). A more universal node would be highly appreciated.

LevL commented 10 years ago

There is node to get underlying curve from model line, and solid geometry of the wall. I wonder if you could provide scenarios when you need differently defined locations for those elements.

andydandy74 commented 10 years ago

In terms of usability and accessibility, a universal Element Location node would make more sense than having to use different nodes depending on what kind of object I'm looking at for essentially the same task - asking an element "Where are you?".

Possible use case: Getting the location of all objects in a selection. Some objects might not be families, but they still have a location (like walls or model/ref lines).

For the time being, I have built a custom node for this which I've uploaded to the package manager.

LevL commented 10 years ago

Node to get Geometry Objects from element could be applied universally.

At some point depending on the object interpretation of notion location (in my understanding) has to be interpreted differently for different elements (say, point vs, wall vs. beam, etc.).

I am interested in examples of application of universal notion of location.

andydandy74 commented 10 years ago

It would behave just like the current Family Instance Location node does:

The only difference would be, that the node also accepts objects that are not placed family instances like e.g. walls or model lines. Wouldn't getting the geometry objects give me solids and faces? In case of a wall, what I'm after is only its curve representation.

LevL commented 10 years ago

I see that you after reference geometry that defined the shape of the element. It might get more complex for floors, ceilings, walls with elevated profiles, etc.

Yes, for walls the geometry objects give solid. It could be exploded and its faces could be cut at desired elevation. So if wall varies with levels you could get proper curve for each level with some computations. Different curves for different levels.

I wonder if you have comment on how (say) such location curve (for some wall) might be used.

Also take simple chair example. Family could be designed so that geometry is displaced from ref plane origin. Will in such case centroid of geometry be better locator for the chair? Or better, centroid of the geometry of the seat of the chair, screened by subcategory (I do not think Dynamo now has access to subcategories of geometry objects, but this is possible to add at first glance). That way if you are seating someone via Dynamo graph the seat will not get missed :-)

andydandy74 commented 10 years ago

I wasn't thinking of anything so fancy as cutting a wall at different heights (although that would be very useful, too). ;-) I think it would be enough if the element's Location property from the API was returned (so depending on the kind of object either Location.Point or Location.Curve). A simple use case would be trying to learn more about the bounding objects of a wall (walls or separation lines).

LevL commented 10 years ago

I think there is API method to return nearby walls for given wall and approximate location. I wonder if python node around that API could be useful. I could find related API methods on Tuesday if this is helpful.

andydandy74 commented 10 years ago

Thanks, I've already built everything I needed as Python nodes. I guess my point here is that it would make sense to not limit the (Family Instance) Location node to family instances since there are other Revit elements that have the same property ("Location").

marcellosgamb commented 10 years ago

I agree a location node for elements would be GREAT! I need to get the locations of Rebar and cant do it with OOTB Dynamo.

LevL commented 10 years ago

Rebar have only view specific geometry, so "geometry objects" node unfortunately will not work. There is Rebar.GetCenterlineCurves method which could be used in python node to get list of rebar centerlines. I doubt it is included in any package. At least not yet :-)