create account

Drag and Drop OpenSCAD with BlocksCAD by makerhacks

View this thread on: hive.blogpeakd.comecency.com
· @makerhacks ·
$9.24
Drag and Drop OpenSCAD with BlocksCAD
![openjscad.png](https://steemitimages.com/DQmfZuxpAKfJFD9RpwDu2mZK56sL7CAZdAn12EKtd68Ny7A/openjscad.png)

[Previously](https://steemit.com/design3d/@makerhacks/getting-started-with-openscad) we looked at how we can build 3d objects programmatically.

While the approach is very powerful ... All of this might be feeling like a lot of hard work.

I get it, even the beginning stuff can seem overly complex. 

Fortunately, there is an easy drag and drop block-style coding option!

https://www.blockscad3d.com/ has all the power, but none of the headaches :)

### Building with Blocks

BlocksCAD3D is a browser-based OpenSCAD tool, but with the twist that you code using Scratch-like blocks.

![blocks.png](https://steemitimages.com/DQmfDxj639tDn6uxjZutPii2krdJxvTRgM28NzHGifqsGWb/blocks.png)

These blocks cover everything from 3D and 2D shape primitives, through to all the transformations and logic operations available in the full OpenSCAD, with the bonus you don't have to remember the names or the parameters!

Even better, the underlying engine is still building SCAD code - that code can be copied and pasted into OpenSCAD, or as we will see, uploaded to Thingiverse for downloads and customizer access ...

### Want to build a Death Star?

As a fun example, we can build a Death Star :)

We will need ...

* A large, dark grey sphere
* The dish part, up high on a side
* A trench around the middle

How do we do this?

Easy!

![death-star.png](https://steemitimages.com/DQmRoAvVLSotbDhnNeuzecHJeTdyAhsJygoHEAzyNZiWkim/death-star.png)

The big grey sphere is obvious as a place to start. Drag the sphere from the 3D Shapes tab.

Next, making the dish shape is the *difference* between the larger sphere and a smaller sphere, which has been put into position.

Our trench is actually a *Taurus* (donut) shape, again cut out of the master sphere.

### Thingiverse

How can we allow other people to play with our model?

That is easy too!

Thingiverse allows you to upload your OpenSCAD code as .SCAD files. 

[Here is my Death Star](https://www.thingiverse.com/thing:2863484)

![thingiverse.png](https://steemitimages.com/DQmc4G6ws1kVbz1cpX8Dowg9vtNaEhNhTP2mFP1omRTog29/thingiverse.png)

You notice you can click through to the customizer and set the Radius.

That is because I created a Radius variable, and instead of setting the radius parameter in my sphere as, say, 50, I set it to the value of the variable:

```
radius =50;
sphere(r=radius);

```

Thingiverse understands that the variable is something we might want to set, and presents it as available in the form.

***Now, obviously, the rest of the values should be set relative to that radius. Right now the Death Star will blow up if you change the radius too much!***
👍  , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
properties (23)
authormakerhacks
permlinkdrag-and-drop-openscad-with-blockscad
categorydesign3d
json_metadata{"tags":["design3d","making","printing3d","programming","design"],"image":["https://steemitimages.com/DQmfZuxpAKfJFD9RpwDu2mZK56sL7CAZdAn12EKtd68Ny7A/openjscad.png","https://steemitimages.com/DQmfDxj639tDn6uxjZutPii2krdJxvTRgM28NzHGifqsGWb/blocks.png","https://steemitimages.com/DQmRoAvVLSotbDhnNeuzecHJeTdyAhsJygoHEAzyNZiWkim/death-star.png","https://steemitimages.com/DQmc4G6ws1kVbz1cpX8Dowg9vtNaEhNhTP2mFP1omRTog29/thingiverse.png"],"links":["https://steemit.com/design3d/@makerhacks/getting-started-with-openscad","https://www.blockscad3d.com/","https://www.thingiverse.com/thing:2863484"],"app":"steemit/0.1","format":"markdown"}
created2018-04-15 23:52:39
last_update2018-04-15 23:52:39
depth0
children2
last_payout2018-04-22 23:52:39
cashout_time1969-12-31 23:59:59
total_payout_value7.805 HBD
curator_payout_value1.434 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length2,736
author_reputation156,977,359,570,955
root_title"Drag and Drop OpenSCAD with BlocksCAD"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id50,280,064
net_rshares1,822,501,316,709
author_curate_reward""
vote details (44)
@creativecrypto ·
$0.35
Hello @makerhacks, thank you for sharing this creative work! We just stopped by to say that you've been upvoted by the @creativecrypto magazine. [The Creative Crypto](https://thecreativecrypto.com/) is all about art on the blockchain and learning from creatives like you. Looking forward to crossing paths again soon. Steem on!
👍  
properties (23)
authorcreativecrypto
permlinkre-drag-and-drop-openscad-with-blockscad-20180419t115734
categorydesign3d
json_metadata""
created2018-04-19 11:57:36
last_update2018-04-19 11:57:36
depth1
children0
last_payout2018-04-26 11:57:36
cashout_time1969-12-31 23:59:59
total_payout_value0.265 HBD
curator_payout_value0.085 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length328
author_reputation1,055,131,252,444,029
root_title"Drag and Drop OpenSCAD with BlocksCAD"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id50,924,277
net_rshares64,688,750,309
author_curate_reward""
vote details (1)
@ethereumcanada ·
$0.12
Awesome. This stuff is so cool and I would love to learn more. You seem to have some really cool interests.
👍  
properties (23)
authorethereumcanada
permlinkre-makerhacks-drag-and-drop-openscad-with-blockscad-20180415t235458136z
categorydesign3d
json_metadata{"tags":["design3d"],"app":"steemit/0.1"}
created2018-04-15 23:54:57
last_update2018-04-15 23:54:57
depth1
children0
last_payout2018-04-22 23:54:57
cashout_time1969-12-31 23:59:59
total_payout_value0.114 HBD
curator_payout_value0.006 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length107
author_reputation19,454,782,690
root_title"Drag and Drop OpenSCAD with BlocksCAD"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id50,280,315
net_rshares24,207,845,175
author_curate_reward""
vote details (1)