Hi, I’ve been trying to use Dynamo to script a way to easily 3D print models, as it has an export to STL function. I’ve been successful so far, but I’ve been wanting to fill in the inside of the house to make 3D printing easier. I was wondering, is there a way to use the outside faces (or entities) as a boundary and just fill in with a solid the inside of the house?
I’ve been experimenting with both this solution:
and my own simple script, which I’ll post once I get uploading permission, which is a simple 12ft by 15ft with a floor roof ceiling and a second inside room.
Another problem with the first solution is doesn’t input a roof or floor and I’m not quite experienced enough (started today) to edit the program to add outside (as in outside of building) roof and floor faces.
Also this does not have to do with filled region boundaries.
After I posted I found that discussion just looking around, but didn’t have success with the script (graph?) you created, as the model still was hollow on the inside - it just filled in any gaps in the walls like doors and windows, which I had left out intentionally as it gave a better contrast in my opinion than adding the doors and windows regularly. So I got what appears to be a solid box on the outside, but a ends up being a completely covered room. (also the reason the roof isn’t there is because I went to an older version of the same model that has a flat roof instead of the sloped on in my second post)
This is what I currently have (The Geometry.Scale is so we can scale in dynamo the base scale (1mm-1ft) to other scales like 1"-16’ or 1’-100’, each number being a conversion. This is not important to the problem).
We also don’t want to edit in meshmaker. The purpose is that I create a script that all the employees can import, hit run, then export STL to go print, a easy workflow that doesn’t involve me messing with 3D model programs (ie, I need to be obsolete, and no one else knows how to use meshmaker or similar programs)
I’ll attempt adding windows and doors to see if that fixes the problem
Added doors and windows, still didn’t flood fill. No holes in the exterior if i just stop at the element.solid, and it just made the side with the door flat so you couldn’t see the door when i did the whole script.Home.dyn (51.9 KB)
Ok, so I found a different solution, I used category (room) > category.element > element.geometry. As long as I rooms are in the houses, it filled in the inside but left the doors and windows alone so they weren’t just flat (I did end up adding them like you said, but before they were just ending up covered).
The new problem is, when you delete a room, it doesn’t get actually deleted, so you have to go delete all unplaced rooms in their schedule. So my (hopefully) last question is, is there a way using a script (graph?) to delete all unplaced rooms before they become geometries?
The script looks through all room areas, then filters out all the rooms that have a area of 0, an area of which only unplaced rooms have. Then it takes the remaining rooms and turns them into geometries.
Thanks for helping me through the process and letting me know it won’t fill without doors and windows, I bet I’ll need that information in the future.
Congratulations on getting this to work, just a couple of things which might be of interest…
As you’ve correctly worked out, you don’t need to union all the elements, it’s enough just to export all the separate solids and the printer will be able to handle printing them. You could therefore not extract the windows (as you had wished) because just extracting the wall will include the opening.
I have found that leaving the inside of the model hollow isn’t a problem, the printer can mostly create the floors and roofs by printing on thin-air. This will give you time savings in printing and reduce the amount of meshes you’re exporting (unless you have enormous spans like an aircraft hanger). Of course, you would need to use your solid rooms method to infill behind in this instance.
If you are going to print your windows you will need to be careful of glass thicknesses (and any other fine detail such as railings) as they will scale down to being so thin they are unprintable. I experimented with using a generic scale factor to compensate but concluded that a global parameter in the Revit model gives the best results. Other parameters such as frame thickness and tolerances might also be included (if you leave even a tiny tolerance the printer can decide to leave a minuscule gap as it’s reading the solids as physically separate).
Finally, if you’re trying to export big models, your method will export a huge quantity of meshes, which creates a huge stl file. My experience is that once you’ve extracted the solids and meshed them, you can then use the Mesh Toolkit and Springs nodes to union them together very robustly, creating a much simplified file (100 meg to 3 meg).
Thanks! I’ve actually been working on it for a little more, and I will say I tried keeping the parts hollow, but this script is supposed to work on everything, and we have a warehouse and other tall and wide roofed buildings in which it just won’t work. The graph needs to be one size fits all, because my boss wants it so our designers don’t have to enough know how dynamo works and run the program and it work every time, print time is a lesser priority, but if I get to print some on my own I’ll definitely keep that in mind. Also, with what you said on windows, I think I’ll just not export them so I don’t have to deal with all the differences like thickness and edges.
Also, can you show me what you mean by Mesh Toolkit and Spring nodes? I have 0 idea how to use them really, though I’ll experiment.
I currently have a different problem - the space between the roof and ceiling is hollow, and the printer cannot handle the slope very well. Is there a way to fill in the gap in between the roofs and ceilings every time? Especially with roofs, there is not really a one size fits all solution that I’ve found, but if you have any idea how this might be possible, let me know. I’ve tried making poly surfaces and extracting solid, but that doesn’t work. Is there a node that lets you create a geometry in between 2 different geometries? Either Room - Roof or Ceiling - Roof, but I only have 1 weeks worth of experience in Dynamo.
One more thing - sometimes the roofs are lower than the room, so a corner of the room sticks out of the roof. Is there a way to use difference to just keep the inside part of the room and make the roof a kind of boundary? I couldn’t think of how to use the logic correctly to do that
Just to answer your query in reverse… The room should be bounded by the roof, but it’s a Revit issue, if you drop in a section to see the extents of the room, then go to Architecture > Room & Area > Computations > Areas and Volumes need to be selected.
That’s exactly the fix I needed! Rooms now fill up to the roof (as long as I set all ceilings to non room bounding). I’ll also take a look at the other stuff you posted, but that right there is what I needed. Thanks!