3D Truss Models
-
Working in earnest on the complex roof module today after spending about two months overhauling the foundation plugin.
As I'm putting together this module I'm starting with a clean slate and trying to take advantage of all my behind the scenes and UI improvements I've made with the updates to foundation plugin and even the electrical plugin. All of the menus for this module will be HTML. Many of the editing and move tools will be brought over from the recent work on the foundation plugin.
The basic parameters that will define the complex roof overall geometry and roof planes are:
- polygon outline (provided by a face or a locus of user selected points)
- pitch
- overhang
- birdcut
- rafter depth
Additional basic parameters will be:
-
rafter width
-
ridgeboard depth
-
ridgeboard width
-
hip rafter depth
-
hip rafter width
-
valley rafter depth
-
valley rafter width
-
framing option: Yes/No
-
advanced roof options
If the advanced roof options are enabled then the roof planes are actually further defined by the sub-fascia width since in two of three sub-fascia types the roof sheathing (plane) actually extends over the sub-fascia.
The advanced roof options will include: sheathing, cladding, sub-fascia, hip-and-ridge, gutters and soffit & fascia. The number of parameter required for all of these options is too numerous to list here. Future advanced parameters might include: gypsum, ceiling joists, heel blocking
Once a complex roof assembly is created it then can be edited by selecting various roof planes and customizing that roof planes particular parameters.
The roof plane edit tool will allow the user to adjust the follow parameters specifically for that roof plane or eave/edge:
- pitch
- birdcut
- rafter depth
- Overhang OR Delta Height (vertical height of supporting top plate)
Additionally certain roof planes will be convertable from a hip configuration to a gable configuration. Once a roof edge/plane is converted to a gable it will then need to be editable with a different "gable" menu, which will include a whole host of gable specific parameters (ie. outlookers, gable overhang, wall sheathing, wall cladding etc...)
Similar to the "Move SOG Edge" tool with the foundation plugin I will also have a "Move Roof Eave" tool that allows the user to move the roof outline around by picking an edge and dragging it perpendicular in or out. This should make resizing a roof a breeze.
I will also have the "Edit Roof Outline" context menu tool which will allow the user to actually edit the polygon that defines the roof outline.
I'm posting this update not only for you but also for me as it is helping me organize some of my own thoughts about what direction I need to take this new development. Any feedback or suggestions on what I have proposed thus far for this new module is very much welcomed.
Just to be clear this module is something I have been trying to accomplish within this plugin since I began coding it almost four years ago. This is the Holy Grail of the Medeek Truss extension. If I can pull this off successfully then I have actually accomplished something.
-
First look at the Draw menu for a complex rafter roof:
When you first click the complex roof icon you are first presented with the initial selection menu:
Once you click the rafter roof option you are then given the draw menu.
I now have the initial supporting infrastructure and templates in place, in other words the boring stuff (ie. attribute library storage and retrieval, draw and edit menus, polygon tool for point selection, global settings).
Now begins the much more challenging and exciting part of the development, establishing the roof planes and the actual geometry creation algorithms.
-
Bravo for the unceasing coding to the perfection!
-
First look at a complex roof primitive created with the complex roof module:
The roof primitive will be placed on the hidden layer and the roof outline (blue colored face) will be placed on the outline layer. The outline layer is important since it allows the moving of the roof edges. Both of these layers are normally turned off but can be turned on manually at any time.
View the model here:
https://3dwarehouse.sketchup.com/model/10c5d29f-eee3-4ff7-8fbc-0686d6e9bc16/Complex-Roof-Test-1
So far the algorithm for generating the roof planes (roof primitive) seems pretty stable, I will have to try harder to break it.
The next step will be the edit functions and then sheathing and cladding, those are the easy ones. After that it is on to sub-fascia, soffit & fascia and gutters.
The most difficult algorithms will be the framing and the hip & ridge.
-
First look at moving a roof edge:
Click to view animation:
Now I need to setup a similar system which will allow certain roof planes to be toggled between hip, gable, dutch gable and half hip. I think I will keep it simple and just start with the gable and hip options first.
Even with only the roof primitive this is already shaping up to be a fairly powerful tool. I like that the entire roof is parametric, I really dislike limitations, both for myself and for the designers who use my plugins.
-
You can also eliminate entire roof planes simply by merging the edges of the roof:
-
Complex octagon roofs are going to get interesting when it gets to the framing:
I will be adding in a separate toolbar for complex roofs with the following tools:
- Draw Complex Roof
- Edit Complex Roof
- Move Roof Edge
- Edit Roof Plane
Some of these tools can also be accessed via the context menu by right clicking on the roof assembly.
-
First look at the Complex Roofs toolbar:
I have removed the complex roof (draw) icon from the main toolbar.
The "Edit Complex Roof" tool will allow the user to manage all of the basic and advanced options for the overall roof. The "Edit Roof Plane" tool will allow the user to select a specific roof plane and edit its specific parameters:
- pitch
- top plate height (vertical offset with respect to the main roof)
- overhang
- birdcut
- rafter depth
If a roof plane meets certain criteria the option to switch the roof plane to an end gable will also be allowed. I have yet to work out all the details or algorithm which will determine whether a roof plane meets this criteria but I do have a pretty good idea on this one, however it may need some fine tuning.
If a roof plane is converted to a gable configuration then additional parameters for gable roofs will be presented in the roof plane edit menu (ie. gable overhang, outlookers, etc...)
-
Still working on the trying to break the roof plane (primitive) algorithm. I've added in a bit more error checking code. It will probably be a couple more days of testing to make sure it is bullet proof or mostly bullet proof.
The edit, move edge and edit outline tools and functions are now all working. The next item of business is the roof plane edit tool.
-
Does it working with curvated perimeter ?
-
-
Even the most convoluted shapes will generate a roof so long as they are closed polygons:
However, I currently don't have a way to create a roof with inner polygons (holes), for example a donut shaped roof. I don't think this is critical right now but I will put this on my todo list.
Just fixed a major performance bug/flaw in the plugin not only for this module but actually for all the plugins. I will be releasing updates for each plugin including the Truss plugin that resolve this issue.
Currently working on the roof plane edit tool.
-
Version 2.5.0 - 09.28.2019
- Fixed a critical performance bug that affects all the modules within the extension.
- Added the Complex Roofs toolbar.
*** CRITICAL PERFORMANCE UPDATE ***
If you are noticing a slowdown of the plugin performance after multiple edits to a roof or floor assembly, this fix will resolve that issue. This issue affects all previous versions of the plugin.
Also note that the complex roof toolbar is now active and will allow you to create a complex roof primitive (edit, move edge, edit outline and regen). The "Edit Roof Plane" tool is currently not yet available.
The roof primitive and roof outline are placed on separate layers, I will get into that more with a future tutorial video. I primarily released this update tonight because of the performance issue I discovered this afternoon with all of the plugins, but it also allows some of you more adventurous designers the ability to test out the new complex roof tools. Granted a lot remains to be done but at least I've got a start into it now. I will be focused on it until it is complete. After that I will attack the secondary roof module.
-
An example of a roof primitive:
(Note, that I've assigned the material of the primitive to a different material and edited it so that it is transparent.)
View model here:
The roof outline is a separate group within the assembly, on its own "outline" layer. I've taken great care to make sure that the primitive is a "solid" so that the user will be able to use SketchUp's boolean (solid) tools to further manipulate these roof primitives if required.
-
All the magic happens here:
Nothing elaborate with my office or setup. The most critical is a somewhat decent computer that works well and the two monitors which allows me to open multiple ruby files at once when I need to.
So busy with the code that I still have not fixed the light fixture base (in the stairwell) that got knocked out of place a few months ago, I guess it all comes down to priorities.
-
Every roof plane will be able to be customized (or have the customization removed and return to its default state where it uses the global settings of the roof assembly).
The first and most important parameter is the Roof Plane Type: Hip or Gable
Not all roof planes will be able to convert to a gable configuration. If you look at a complex roof you should only be able to turn the roof planes that form a triangle (defined by three vertices) into a gable configuration. All other roof panes are going to be inclined or "hip". The other constraint is that the angle between the roof plane in question and its adjacent roof planes on either side must be orthogonal (90 degrees), otherwise you could potentially try and gable a roof plane on a octagon shaped roof, which would not make any sense. I think these two constraints will successfully limit a roof plane, as to whether it can become a gable end.
If a roof plane is customized and it is a hip its parameters are:
- pitch
- birdcut
- rafter depth
- overhang
- delta height
If a roof plane is customized and it is a gable end its parameters become:
- gable rafter option
- gable rafter depth
- gable overhang
- rake option
- rake width
- rake depth
- outlooker option
- outlooker spacing
- outlooker size
- outlooker orientation
- outlooker structural: Yes/No
- outlooker @ peak: Yes/No
P.S. A certain situation exists where the roof plane has 4 vertices might also be able to be a gable end, I will study this further.
-
Customizing roof planes gets a little complicated when combined with the roof edge move tool. The problem is that as you move roof edges you potentially change up the shape of roof, eliminating certain roof planes entirely and also changing some roof planes that potentially could be gable ends back to a hip configuration and vice versa.
With custom roof planes the move tool is going to have to get a bit more elaborate (more logic) so that a number of checks can be run to make sure that we are not trying to turn certain roof planes into gable ends that physically cannot be this configuration and also checking to see if certain roof planes were deleted.
The outline edit tool is even a larger problem in my opinion. How do you know which edges were retained after an outline edit? I think the default behavior should be to erase all roof plane customizations after the outline edit tool is used. I will need to give this some further thought.
Somehow I always knew that complex roofs was going to be a bit of a Pandora's box.
-
First look at the Edit Roof Plane menu and tool in action:
Now that we are able to successfully select roof planes (roof edges) only the algorithm for gable end flagging remains. If a roof plane cannot be converted to a gable end the "Roof Plane Type" drop down option will be limited to only a "Hip" type.
-
Thanks for the thread and the explanation, that's extremely useful for us newbies! Especially since I got a task that's a little bit out of my league at work: do some 3D models for some of this Cannes real estate, while I'm glad if I can do something like an ice cream cone or a basic child drawing house...
-
Lots of little details when it comes to editing roof planes. First of all let's introduce an updated menu:
Notice that the roof plane status will tell you whether the selected roof plane is inheriting its parameters from the main roof or it has its own custom settings.
I've also added a "Clear Custom Settings" at the bottom of the menu so that one can return the roof plane to the default/global settings of the roof assembly.
Setting up all of this supporting infrastructure is somewhat tedious and certainly time consuming, however I do believe that a solid user interface that is both efficient and intuitive will make or break this module.
I intend for the edit plane tool to be persistent, provided that it does not affect stability. In other words you can keep clicking on roof planes and updating them without having to restart the tool by clicking on the icon in the toolbar.
Advertisement