Level of a component
-
Hi everybody,
First of all, i'm french and it's my first message on the forum. So please excuse my english which is not as fluent as i'd like.
I'm working on a plugin which exports all the components in a csv file and i need the property that gives the level of the component.
Can you help me ?
Tks,
Boris
-
You can find the parent of an entity. I don't believe there is a built in method to retrieve the entire tree. However, you can build the tree yourself. Take a look at the following SU API documentation page, especially the "parent" entry.
http://code.google.com/apis/sketchup/docs/ourdoc/entity.html
-
@boris vaisman said:
Hi everybody,
I'm working on a plugin which exports all the components in a csv file and i need the property that gives the level of the component.
Hi Boris
Your English is great however I can think of at least four meanings for the english word "level" that you might mean. If Davids answer doesnt help perhaps you could indicate which(if any) of these you mean?
-
In a building : "level" can refer to the floor or story of a multistory building. Example "The entrance is on level one, the kitchen is on level two." means the entrance is on the bottom story and the kitchen on the second story/floor.
-
In a hierarchy : "level" can be used like David has to refer to the how far "up" the hierarchy / tree your object is.
-
In ?physics/geometry/building : "level" can mean "flat" or perfectly horizontal/vertical. Example "That window ledge is not level" means the window ledge is not perfectly horizontal.
4 In CAD programs : "level" might refer to a "layer" . Example "Draw your house floorplan on level 0 and then draw 3D elements on other unique layers eg level 1 - 20".
cheers
Paul
-
Advertisement