Construction Lines add-on - CAD - Released

It’s very interesting work that you’re doing, I’ll definitely be keeping an eye on this. It’s a really important step for Blender. My aim for the next add-on is to facilitate drawing document outputs (.pdf, etc.), scaled, with full dimensions, section cuts, annotations and multiple views. It’s different to what you’re doing but it’s all pushing Blender’s CAD abilities.

@Meetlat Thanks for pointing this out.

1 Like

Hey Dan,
in your quest to sketchupify Blender, would you also consider spreadsheet capabilities and quantity take-off, such as in Sketchup Pro? This is severely lacking in Blender, and no other add-on seems to offer this.
I’m sure lots of AEC professionals are eagerly waiting for this.
I am aware of BlenderBim of course, but at the moment it is all very rudimentary, and anyways it requires you to apply the full BIM/IFC workflow, which frankly is a pain for smaller projects.
Thanks!

1 Like

Hey @bahum,
It’s not something I use for my own work so just to confirm, do you mean producing spreadsheet data with quantities based on material type and then automatically calculating cost based on unit price and quantities required - taking into account standard material size (sheet materials, etc.).
Thanks.

If you’re in the AEC world, at some point your building is going to be built. For that to happen, you need a lot of information about the building and its components, for assessment of its feasability, its energy use, and also for communication with building contractors for instance, things like areas, volumes, length, width, height etc, just to name a few.
So in Sketchup Pro you can export a lot of these data about your objects, in a CSV file (the report function). It is exactly this capability that is lacking in Blender. So as an architect or engineer, at the moment you’re stuck in Blender, the reason being that Blender at this point is not covering enough of the workflow in AEC. That’s understandable, Blender has never been conceived for this.
But still, the lack of export capability for basic information is a sore point.
Simple object info like: object length, width, height, area of the faces, object volume, object name, layer the object is on, collection the object is part of, etc… would be a great start. If we just could export this basic info in a CSV file, then we could import it in a proper spreadsheet for further calculations of any kind.
So just Sketchup-like export capability of basic object info would make already a world of difference. No complicated things like cost calculation etc…, if I need more complex info in the design process, then BlenderBIM would be the way to go.
Thanks for considering this, you’re doing a great job!

1 Like

@bahum the BlenderBIM Add-on supports scheduling of data from IFC. However, as you say, this does require you to apply the full BIM/IFC workflow. It may be easier than you think to quickly assign and convert. If you’d like, I can demonstrate this process.

However, steps have also been made to start supporting non-IFC features. For example, clash detection now works within Blender itself too without needing IFC. There may be a usecase to build a scheduling feature sans-IFC too.

1 Like

Hey Dion, you seem to be everywhere!
Let’s not hijack this thread, it’s meant for Construction Lines :slightly_smiling_face:
Just this: a lot of great work for the AEC community is being done in the Blender add-on world right now: Construction Lines, Archipack, BlenderBIM, Sverchok, Topologic…exciting stuff!
At the same time I can’t help noticing that these are mostly one-person initiatives, and I am a little bit uneasy about that.
The same goes for Freecad.
Unfortunately I am not a programmer, so I cannot help.
Multiple parties developing the same features seems not a bad idea to me for future-proofing the AEC-workflow in Blender. Meaning: Construction lines having a Sketchup-like basic export function, and BlenderBIM having an advanced export-feature may seem like a waste of energy, but I see this as complementary. Construction Lines is meant to make Blender very accessible for newcomers from Sketchup, while BlenderBim is quite advanced.
It seems to me that there is a place under the sun for both, don’t you think?

What I want is to model in a similar way as in SketchUp and have it come out as high quality line art for use in Art and Comics. Hopefully CL will soon give me a lot of what I want with the modeling, but the output as line art is a disaster right now. Freestyle ignores places where there should be lines (even when marking the edges) and places lines where there should be none. Freestyle can also have missing parts of lines. But Freestyle almost render the lines at acceptable level. Then we have LineArt, it renders the lines with fewer mistakes, but the output is a jagged mess. Freestyle is more easy to use and there are work going on to make it more easy to use. LineArt is more of a mess to use and set up and I don’t know if it has gotten any development since November last year and it’s also not in a stable Blender release. With other words, with any kind of presentation, Blender is a far way from SketchUp in any kind of output that is not a typical render. I’m afraid developers like @norrid and others might get discouraged by the overwhelming stuff us users wants out of Blender and add-ons for Blender. Maybe these kinds of points should be a part of a larger discussion with some core Blender developers, add-on developers and some professionals from communities that has not seen much support in Blender, but are growing. Communities like CAD, Architects, Animation with 2D elements, NPR, 2D artists/Illustators, Graphic Artists. Blender can do more and more, but that also mean things are missing in many areas. There is a need for new tools to address those areas. However my point of all this is that one tool made in the right way might address more kinds of issues and a large discussion might address areas that would otherwise be left broken or as a dead end.

I don’t know how or who can take this further. I’m not a pro at anything. Right now I’m mostly just happy and excited for for the development of CL and whatever Dan will tackle next. Same with LineArt, BNPR and other projects. But yeah, I wish more areas/projects and problems had more developers.

1 Like

Hi Jimmy, Good luck with the transition to Blender. I’m really looking forward to the latest CL update too.
This thread is for CL and you will get more information regarding NPR style output here:

1 Like

@tuulikk: do you know the Sketch Style add-on?

Yes. I have talked to the maker of it, Chipp Walters, and according to him the line rendering is still done with Freestyle and my problems will probably not get fixed with it. Thanks for the suggestion however.

I started writing a response to this and figured it was easier to knock up a quick script. It’s rudimentary but I just want to understand a bit better what would be required. If the output data is simple like this, I think it would make sense to create it as a separate add-on, outside of CL and put on Github so that it could be developed as a community.

My worry is that I think it’s something that could quickly become very complex, especially if objects were not built as expected and if curved objects needed to be catered for.

Anyway, let me know if this is the sort of thing you’re thinking of. Paths are hardcoded so change as fits.
Select some objects and paste the script into the Scripting Workspace (click +New first), then click Play.

import bpy

FILE_PATH = "c:/temp/blender_quant.csv"
DELIMITER = ","


def unit_scale(b_unit):
    return {
        "KILOMETERS": 1000.0,
        "METERS": 1.0,
        "CENTIMETERS": 0.01,
        "MILLIMETERS": 0.001,
        "MICROMETERS": 0.0000001,
        "MILES": 1609.34,
        "FEET": 0.3048,
        "INCHES": 0.0254,
        "THOU": 2.54e-5,
    }.get(b_unit, 1.0)


def construct_field_ids(context):
    unit = context.scene.unit_settings.length_unit

    return "Name, Width({0}), Length({0}), Height({0}), Volume({0}^3), Material, Collection".format(
        unit
    )


def quantify_selected(data, context):
    data.append(construct_field_ids(context))
    scale = unit_scale(context.scene.unit_settings.length_unit)

    if context.mode == "EDIT_MESH":
        bpy.ops.object.mode_set(mode="OBJECT")

    selected = [obj for obj in context.selected_objects if obj.type == "MESH"]

    for obj in selected:
        w, l, h = obj.dimensions
        w /= scale
        l /= scale
        h /= scale
        mat = ""
        if obj.active_material:
            mat = obj.active_material.name

        row = [
            obj.name,
            str(round(w, 4)),
            str(round(l, 4)),
            str(round(h, 4)),
            str(round(w * h * l, 4)),
            mat,
            obj.users_collection[0].name,
        ]
        data.append("\n" + DELIMITER.join(row))
    return data


def save_to_file(data):
    f = open(FILE_PATH, "w")
    for row in data:
        f.write(row)
    f.close()


obj_data = []
quantify_selected(obj_data, bpy.context)
if obj_data:
    save_to_file(obj_data)
else:
    print("error: No object data")
2 Likes

Hi Dan, many thanks!
I’ll definitely check this out over the weekend.
I didn’t mean to pressure you, so I’m really surprised at this.
I just wanted to point out where Blender is severely lacking for use in the AEC-workflow, and of course I was hoping for a solution.
I’ll report back to you after the weekend.

2 Likes

No problem at all. There was no pressure, I just felt it was quicker to write a script to show what I think you meant, rather than ask a lot of questions. It might not be anything close to what you’re after but I’m interested to know, if it was developed further, would it meet your needs.
I need to mainly focus on Construction Lines but if I can help push Blender towards a more CAD-based and or Sketch-Up like workflow, I’ll do what I can.

Sorry Dan, I unexpectedly had to help out a friend this weekend, so couldn’t test your script.
I’ll do that as soon as I can, possibly next weekend.

No problem, there’s no rush at all. I’m tied up with work and Construction Lines testing\bug fixing at the moment.

2 Likes

Hey Dan,
I purchased the add-on and find it really useful in certain situations.

However I’ve scripted my own custom pie menu that allows to switch between the standard built-in select box, activating Construction Lines and a few other add-ons I regularly use. I assigned the key F18 to this menu. I can easily switch into every single mode including Construction Lines, but CL is the only one that blocks the assigned hot key. It seemingly blocks every key press that is not defined by CL.

Is there a way to circumvent this? It would be fine with me to include a scripted “ESC”-keypress to exit CL mode into the pie menu, but for that I would have to be able to call it first.

Thanks a lot in advance.

2 Likes

Hi Leo,

Because of the way CL works, I tend to absorb most key presses and not pass them through to Blender. It’s mainly to stop any unwanted behaviour. If you’re using F18, is this with a Shift+F6 or something along those lines? It may be that I’m blocking the Shift key as I store it for various operations. Let me know how you do it and I might be able to pass it through so your menu can work.

1 Like

Hey,
thank you for your reply and the explanation. I used to use the F13-F19 keys natively without modifiers as they exist as individual keys on the full-size Apple keyboard and I thought those for sure would never be in conflict with anything. I’ve also mapped this hotkey to one of the spare mouse buttons of my Logitech mouse. It sends the native keypress without modifiers like Shift.
A hack I came up with is to use the Logitech software to bind the button to ESC + F18. So CL is always exited first and then the hotkey binding is triggered in Blender. However ESC is also send upon a button press when the other options are active. It seems tow work right now, but at the same time feels as if it could cause problems down the road.
Thanks again for looking into it.

1 Like

Hi, when was the last update i feel like a century ago :wink: where are we with the extrude tool?
and do you work on a knife tool ?

Hi Leo,

It’s good that you’ve found a workaround for the short term. I’m planning to re-do the keymap system in CL fairly soon, so that all hotkeys can be reasigned in preferences. So hopefully that will solve the problem for you.

1 Like