Replacing OpenScad with Vraag Construct

OpenScad is often used to construct models for 3D printing, and it has a nice Syntax. But it is not Python, and when exporting objects from OpenScad into Blender all you get is a mess of polygons.

That’s why I am working on “Vraag Construct” as part of “Blender Vraag”, a JQuery-inspired higher-level API for scripting Blender. Vraag Construct allows you to create hierarchies of parented objects, setup materials, names and even boolean modifiers.

Because everything is “just” Blender data objects, you can debug your geometry directly in Blender, animate or even simulate the individual components.

For example:


V("#cube").remove()
empty = V.construct().translate(up*3).empty()
for p in empty.rotator(axis=up, n=10, radius=4):
    root.cube()

This code removes the default cube, creates an empty object with 10 cubes rotated around it. The cubes are parented to the empty object.

There is still a lot missing: Primitives like spheres, cones, monkeys, etc, scene and layer changes, object linking and various other things could be added.

If this sounds interesting, just try it out and let me know what you think of it!

Will have to give this a look next time I have a chance.

I’m a little confused about the primitives. Is this creating it’s own primitives or using the ones “built-in” to Blender?

Nice project. I will take a closer look to your project this weekend.

Hopefully this will evolve into something more parametric. I badly need a multi-platform parametric design software to design furniture and staircases, and the big problem is that all the software’s who can do this are Windows based. I’m looking to Blender as a possible alternative but unfortunately will need tons of work to get to an usable level for my needs. But not impossible, as we have BlenderCAM project for generating the Gcode for CNC machine and also some other small addons related to CAD design.

I thought by myself to create some python scripts who can read/write information from/to an external database or excel file and use the information from there to parametricaly adjust geometry inside Blender.

@artisanicview: Have you looked at Sverchok? http://nikitron.cc.ua/sverchok_en.html

I think that I will need some more step by step tutorials to fully understand how this is working.

Anyway, seems quite powerful, half way of what I need.

Only need 2D support and a customizer like this OpenSCAD customizer.