I have a few small objects that have been subdivided into multiple levels, with each level further divided into smaller parts based on specific part sizes.
My goal is to select the uppermost or last-level divided surfaces for each object. In the attached GH file, I’ve attempted two methods. The first one is to create bounding boxes for the original surfaces and their divided counterparts. Then, I dispatch the divided surfaces based on the lower points’ z-coordinates of the original surfaces’ bounding boxes.
The second method focuses on dispatching surfaces whose normals do not match the normals of the selected original surfaces. Unfortunately, neither method has produced the desired results.
@maje90 Hi Riccardo, I internalized everything already, however, the white components that did not load, likely because of variations in Elefront versions. However, I’ve replaced all the components with standard ones from Grasshopper. Please find the updated file attached.
I hope it is clear and working for you now.
@maje90 I really appreciate your help in addressing the solutions for this. You were absolutely right about my approach to selecting surfaces, it wasn’t effective. I believed there had to be an easier way to tackle it, just like the options you shared.
I also have another question that is very related to the previous question and the topic as well, but it deals with specific points rather than surfaces. After selecting the last-level elements of the objects, I’m looking to re-order the points based on a specific sequence. Once I have that sorted, my next step is to pick out and separate the corner points of the last-level surfaces from the regular ones.
I’ve included the Grasshopper file below, where I’ve attempted to collect these specific points, but I didn’t quite achieve the desired result. The selected points ended up with a different list structure, and the adjacent surfaces that share the same edge points have also been selected. Do you have any suggestions on how to accurately select and separate these points?
Here’s an example, less elegant than what @maje90 has provided, but feeds off your intention to use the local coordinate system at each group by evaluating a union bounding box (therefore establishing the reference plane) per each: SURFACES SELECTIONb.gh (288.7 KB)
The List Item component at the end shows you both uppermost sets of divisions.
What should this sequence be?
Meanwhile, not 100% I follow, though going off of the example I shared, plus coming from your original data, and quickly guessing from the corner faces and corner points you seemed to be picking: SURFACES SELECTIONc.gh (298.6 KB)
@René_Corella Hi René, thank you for your explanation and for sharing the solution with me, this is what I was trying to achieve from the start, but I could not execute it correctly. However, as you mentioned what @maje90 has provided appears to be a better and simpler option, as it preserves the data structure of the selected surfaces.
Thanks again.
SURFACES SELECTION-V02.gh (287.7 KB)
I dislike it.
You should do your project from scratch and create those panels with a proper order from the start.
Notice how the bool pattern is true-false-false-true , so the corners are for now always the first and last element. But the element in between are not sorted!
If you don’t care about that, you can simply make a True-False list and grow it with longest lists set to repeat last, and lastly replace the last element with a True…
@maje90@René_Corella I truly appreciate your explanations and the solutions you’ve provided.
What I’m trying to achieve involves selecting the last-level elements of the objects, as we’ve done already. My goal is to rearrange the points according to a specific sequence, as I’ve done and illustrated in the screenshots below, showcasing the comparison between the old and new points order. Once all the points belonging to these surfaces have been re-ordered, I aim to have the corner surfaces’ points and the regular surfaces’ points separated from each other while keeping the original data structure. This grouping will enable me to carry out additional operations on each group separately.
Let me provide a more in-depth explanation of the issue I’m encountering. In my current approach to point separation, I’m encountering an unintended selection of points. Specifically, when I isolate the points, it’s not just the corner surfaces’ points that are being selected, but also the two points from the adjacent regular surfaces that share the same edge. This results in the loss of two points from the regular surface and an additional two points are being added to the corner surfaces’ points group for every adjacency occurrence.
Ideally, instead of this, I should only be working with four points that pertain to their respective corner surface and four points for each regular surface, without any loss in the process.
I’m sorry but I don’t understand this last one.
All of this convoluted logic is only because you are starting from unsorted data.
The initial facade surfaces and subdivision should have been ordered, sorted, done in a way to keep a logical structure.
You are wasting your time by trying to fix, after, what should have been correct since start.
Also all this “select” this and that… explain what are you aiming to, maybe we can suggest a better way to handle it all.
This thread is becoming a “do stuff for me”.
I’m not fully against that. But I prefer when any effort can be useful. Really useful.
All solutions in this thread are too specific, even for yourself. You won’t get any advantage in future from this.
Real advantage: learn to work with properly sorted data and let’s talk about how to “navigate” datatrees.
Riccardo, I appreciate your message. I completely grasp the importance of having well-structured, sorted data right from the outset, as it can certainly save time and avoid problems in the future.
Please know that my intention was not to seek a complete solution from you, and I apologize if it came across that way.
Regardless, I’m in complete agreement with your point about the importance of improving my ability to work with meticulously organized data for future problem avoidance.
Once again, thank you all for your help.
Not sure about preserving however I’d say what I did ‘in the blind’ (not fully knowing what you actually intended) retrieved the structure - I assumed the difference in the data structure from the start was like that for a reason given the difference of surface divisions in multiple directions/quantities - furthermore, I evidently didn’t sort the points as I didn’t know yet what order/sequence was desired. Anyway, fun stuff!