Grasshopper multiplication graft not working

Thanks @Joseph_Oster ,

I would like a way to figure out how to trim the door openings in a faster method. SDiff works well for this kind of case but if we were to extrapolate this to a building with say 100s of doors and one door gets moved, it would have to recalculate the SDiff component each time which would (I think?) introduce a noticeable hiccup.

I’ve messed around with projecting curves,surface splitting, lofting, building the walls from the start with the door openings considered, etc. but haven’t landed on a method I really am happy with yet. Any ideas would be appreciated! Or if you happen to have a blazingly fast SDiff script or something lying around, that would be awesome to see!

Regarding this point:

This is determined from the “Door Pivot Offset” slider in the “Control Panel”.
If you set it to 0 it will be a standard hinge door as you would typically see in most applications but I wanted to add the pivot offset in case the user wanted to have a pivot door.

image

While I don’t often use pivot doors in my projects, it’s nice to have the option when needed.

Rotation is set to 45 degrees but not limited. You can rotate the doors to 360 degrees if desired but I set to 45 just for the example. I did cap the slider for “Door Rotation” at 90 but you can override this value as desired and you could even do negative rotation though your door would clip the frame as currently its set to rotate “away from” the frame as a hinged door would.

I totally understand that and it’s just my preference. I’ve ended up with some laughably large prototype definitions, such as this one ~8000 components and counting (after many reductions and refactorings). And breaking it up the way I did and hiding the wires is the only way my mind can keep track of everything haha. The final code won’t be this bloated and hopefully much of it will become scripted. But for now, it is what it is; not saying it’s the right way or works for everyone but it works for me :upside_down_face:

The horror show (only half the canvas):

Cheers!

2 Likes

Aha! I missed that slider setting.

I see the ‘Rotate’ slider limited to 45, which is why I asked. You have it set to 43.33.

YIKES :exclamation: Sounds like you might want to use Hops to break it up into manageable pieces?

1 Like

Oh then that’s just an error on my end.

Yes, hops is a contender to help. It’s all Rhino 8 though so I’m waiting for hops to play with R8 (I think I just saw a post it does now or is coming soon)

Longer term, for that I’ll probably need to hire someone to properly program it all but for now it’s intended to showcase functionality, ideas, and features

Ok, i didnt know the existance of entwine who look really interesting and better than merge for this.
I’m still trying to understand well each step not that easy !
thanks :slight_smile:

The Suirify component is superb for this. ‘Params | Util | Suirify’. It does what you expect from ‘Simplify’, which doesn’t always work as well for this purpose.

suirify

1 Like

I’ve not used suirify but will certainly check it out, thanks for sharing!

It always works when simplify doesn’t - named after a forum member who requested it: @osuire

2 Likes

Cool bit of history!

1 Like

Not that it matters to the point of this thread but I added SDiff to cut door holes in existing walls, modifying the ‘Polygon Test Geometry’ group to the left of the canvas. It passes four parameters to the right for the “main code” to work with:

  • Door Lines (as before, they determine position, width and hinge / handle locations)
  • raw wall
  • Wall Thickness
  • Wall Planes

I added the door handles, which was quite a bit more code.



Door_in_wall_2023Sep1c.gh (60.3 KB) (UPDATED again)

Doors are limited to 178 degrees rotation to prevent the handles from hitting the outside walls.

P.S. Updated to version ‘Sep1b’ due to rotation bug when ‘Door Width’ was changed.
(How does the addition of a Unitize Vector component increase file size by 10K :question:)

P.P.S. RATS :exclamation: Found another bug.
On doors with hinges on the right, the handles are misaligned. :roll_eyes: :zzz:

Later - Updated to version ‘Sep1c’ to fix misaligned handles.

1 Like

I almost didn’t do this… It got so complicated I considered other methods. I finally got it though. :sunglasses:

The last hurdle was implementing doors that open in either direction. I made no changes to the “main code”, only the ‘Polygon Test Geometry ’ group to the left of the canvas. I added the white group at the bottom which is driven by a text panel pattern of zeroes (“in” as before) or ones (“out”). It modifies the ‘Door Lines(moving them inside the wall for doors going out) and the “Wall Planes(flipping them for doors going out).

Notes:

  • Wall Planes are actually HFrames (XY planes aligned with each wall segment). There was one plane per wall segment but now there is one for each door.

  • The ‘In or Out’ pattern in the text panel repeats as needed. A pattern of zero and one will affect every other door on each wall segment, no matter how many doors. A single zero causes all doors to be “In” (swing out), a single one causes all doors to be “Out” (swing in).



Door_in_wall_2023Sep2a.gh (64.2 KB)

It’s possible this code could be simplified… :thinking:

2 Likes

Hey to you make work this i try to move the slider but its not working :confused:

Sorry could you be more specific? Which slider ?

Yes its not really precise !


i dont arrive to make it work well this part of the script :confused:
i have this :confused:

i think the script need just a little adjustment but cant find where

Hi @Julien_B , so that particular slider is selecting a subcurve of your door frame profile.

lt looks like your profile has maybe 10 or so curves in it so a slider value of 37 would not really be appropriate here, you’d want a value like 4 or 6 or something within the range of possible subcurves.

All that slider is doing is “marching” through each possible subcurve, allowing you to select the one you want for your frame alignment with the wall.

I would need you to upload the script with any geometry such as your frame profile internalized to see what the issue is exactly.

There i upload the script i change the slider to 12 the right number but it doesnt change the problem …
230918_Door.gh (80.6 KB)

Hi @Julien_B ,

The intent of the “Select Point On Door Frame To Orient From” group is to use the slider to select the leading, dominant “interior” edge of the frame. That is, the frame profile edge that would be touching your wall framing/rough opening edge.

As you mentioned you chose 12 here but if we take a look at your frame profile index sub curve 12 is actually a very small edge and index 0 is the “leading interior edge” we want for our alignment.

image

Please see diagram here with W representing the wall:

I did find a couple small items that I updated in the script to handle use cases such as what you presented.

-In group A, I added a boolean toggle in the control panel to be able to “Flip Frame Direction” should the frame be oriented opposite of expected. (Such as in the use case you provided)

-In group B, I added a little bit of additional logic to ensure we return the “max frame width” should the frame width test fail to return the widest two points. (As was the case with your frame profile you provided)

-In group C, I added clamp components to ensure that the Door slab can never be set past/outside of the wall depth regardless of slider value. In other words, make sure the door is never floating in space but always within the “bounds” of the frame/wall assembly.

Hopefully this helps, let me know if you have issues or get stuck.

Cheers!

20230919_Door_Response_01a.gh (81.3 KB)

Oh, so good and amazing! I just opened it, but it’s missing just one component, and I don’t know which one it is!
Screenshot 2023-09-19 at 21.19.31

1 Like

Oops, that’s the clamp component and it must be exclusive to Rhino 8.

I’ll upload a version that uses the Remap Number component instead which can do the same exact thing and should work just fine in R7

1 Like

Ahaha yes thank you you are too much in advance :wink:

1 Like

Here you are @Julien_B ,

This one should work in R7

20230919_Door_Response_01b.gh (85.1 KB)

2 Likes