The Belfry OpenScad Library, v2.0. An OpenSCAD library of shapes, masks, and manipulators to make working with OpenSCAD easier. BETA
Find a file
2023-05-21 21:00:05 -07:00
.github Moving to BelfrySCAD org. 2023-05-21 21:00:05 -07:00
examples BOSL2 logo source fix. 2023-04-28 17:10:49 -07:00
images Added logo to README. 2020-12-30 15:44:17 -08:00
resources PDF font size tweaks. 2023-05-09 18:08:32 -07:00
scripts Moving to BelfrySCAD org. 2023-05-21 21:00:05 -07:00
tests bug fix 2023-05-15 20:02:07 -04:00
tutorials fix closed=true stroke calls with endcaps given 2023-04-23 23:36:07 -04:00
.gitignore Improved mkdocspdf.sh 2023-05-08 16:45:38 -07:00
.openscad_docsgen_rc Synopses, etc for skin.scad 2023-05-01 00:32:49 -07:00
.openscad_mdimggen_rc Make docs use PNG animations. 2023-02-03 12:09:46 -08:00
affine.scad Syntags for affine.scad, attachments.scad, ball_bearings.scad, beziers.scad, bottlecaps.scad. 2023-05-09 18:04:29 -07:00
attachments.scad Fixed corner_profile() and edge_profile() to allow negative-rounding and chamfering. 2023-05-14 03:16:26 -07:00
ball_bearings.scad Syntags for affine.scad, attachments.scad, ball_bearings.scad, beziers.scad, bottlecaps.scad. 2023-05-09 18:04:29 -07:00
beziers.scad Syntags for affine.scad, attachments.scad, ball_bearings.scad, beziers.scad, bottlecaps.scad. 2023-05-09 18:04:29 -07:00
bosl1compat.scad doc fixes 2022-10-23 08:05:40 -04:00
bottlecaps.scad Syntags for affine.scad, attachments.scad, ball_bearings.scad, beziers.scad, bottlecaps.scad. 2023-05-09 18:04:29 -07:00
builtins.scad bug fixes for "default" color 2022-03-20 09:03:18 -04:00
color.scad Added SynTags to color.scad 2023-05-14 03:16:51 -07:00
comparisons.scad epsilon issues. 2023-04-19 17:34:33 -07:00
constants.scad Docs tweaks for colors.scad, constants.scad 2023-05-11 20:53:31 -07:00
CONTRIBUTING.md Moving to BelfrySCAD org. 2023-05-21 21:00:05 -07:00
coords.scad Enabled coordinate translations of lists of coords. 2023-05-14 03:17:41 -07:00
cubetruss.scad Reviewed gears.scad and cubetruss.scad for Usage 2023-04-04 20:29:21 -07:00
distributors.scad Distributors.scad synopses 2023-04-01 17:20:23 -07:00
drawing.scad fix closed=true stroke calls with endcaps given 2023-04-23 23:36:07 -04:00
fnliterals.scad Synopses, etc for fnliterals.scad 2023-05-02 21:37:03 -07:00
gears.scad Reviewed gears.scad and cubetruss.scad for Usage 2023-04-04 20:29:21 -07:00
geometry.scad Changed Wiki style links to Markdown style links, for future compatability. 2023-05-04 21:15:31 -07:00
hinges.scad Added Synopses, etc to hinges.scad and joiners.scad 2023-04-03 20:11:36 -07:00
joiners.scad Fix for joiner bug #1167 2023-05-18 03:00:17 -07:00
LICENSE Updated copyright years. Split math.scad up. Enabled attach for lots of shapes. Removed backwards compatability. 2019-04-19 17:02:17 -07:00
linalg.scad fix missing Synopsis 2023-04-30 23:02:43 -04:00
linear_bearings.scad Review linear_bearings.scad and sliders.scad for Usage line syntax. 2023-04-04 21:00:31 -07:00
lists.scad Negative indexing in list_set and list_insert 2023-05-15 18:51:37 -04:00
masks2d.scad SynTags for masks2d, masks3d and partitions 2023-04-14 15:53:35 -07:00
masks3d.scad SynTags for masks2d, masks3d and partitions 2023-04-14 15:53:35 -07:00
math.scad lookup_vector() -> v_lookup() 2023-05-01 21:49:39 -07:00
metric_screws.scad Merge branch 'master' of github.com:revarbat/BOSL2 into revarbat_dev 2021-12-13 15:51:06 -08:00
modular_hose.scad Synopses, etc for modular_hose.scad, nema_steppers.scad, polyhedra.scad 2023-04-05 19:16:15 -07:00
mutators.scad add attachable to bottlecaps & mutators 2023-04-27 22:15:10 -04:00
nema_steppers.scad Synopses, etc for modular_hose.scad, nema_steppers.scad, polyhedra.scad 2023-04-05 19:16:15 -07:00
partitions.scad SynTags for masks2d, masks3d and partitions 2023-04-14 15:53:35 -07:00
paths.scad Synopsis tweaks and cleanups. 2023-03-30 19:28:29 -07:00
polyhedra.scad add attachable to bottlecaps & mutators 2023-04-27 22:15:10 -04:00
README.md Moving to BelfrySCAD org. 2023-05-21 21:00:05 -07:00
regions.scad Synopses: regions.scad 2023-04-04 23:36:14 -07:00
rounding.scad bug fix 2023-05-15 20:02:07 -04:00
screw_drive.scad screw_drive.scad docs fixes. 2023-03-31 20:13:20 -07:00
screws.scad Fix hex head bug. 2023-05-18 12:41:46 -04:00
shapes2d.scad Shapes2D SynTags 2023-04-14 13:42:53 -07:00
shapes3d.scad Moving to BelfrySCAD org. 2023-05-21 21:00:05 -07:00
skin.scad Moving to BelfrySCAD org. 2023-05-21 21:00:05 -07:00
sliders.scad Review linear_bearings.scad and sliders.scad for Usage line syntax. 2023-04-04 21:00:31 -07:00
std.scad Merge pull request #804 from adrianVmariano/master 2022-03-18 13:26:03 -07:00
strings.scad Synopses, etc for strings.scad 2023-04-28 19:23:15 -07:00
structs.scad Synopses, etc for structs.scad 2023-04-28 18:50:51 -07:00
threading.scad fix various stroke() bugs, add attachable() to some modules 2023-04-23 21:38:27 -04:00
transforms.scad Trans SynTags for transforms.scad 2023-05-12 11:21:43 -07:00
trigonometry.scad Synopses, etc for trigonometry.scad 2023-04-28 18:39:26 -07:00
tripod_mounts.scad Synopses, etc docs added for screw_drive.scad, screws.scad, sliders.scad, threading.scad, tripod_mounts.scad, walls.scad 2023-03-31 20:08:00 -07:00
turtle3d.scad Fixed truncated docs problems. 2023-03-28 21:53:01 -07:00
utility.scad Fixes for utility.scad docs. 2023-04-30 20:16:43 -07:00
vectors.scad Synopses, etc for vectors.scad. 2023-04-28 17:40:11 -07:00
version.scad Added Synopses, etc to lists.scad, version.scad, wiring.scad. 2023-03-31 00:20:27 -07:00
vnf.scad fix closed=true stroke calls with endcaps given 2023-04-23 23:36:07 -04:00
walls.scad Synopses, etc docs added for screw_drive.scad, screws.scad, sliders.scad, threading.scad, tripod_mounts.scad, walls.scad 2023-03-31 20:08:00 -07:00
wiring.scad fix various stroke() bugs, add attachable() to some modules 2023-04-23 21:38:27 -04:00
WRITING_DOCS.md Update WRITING_DOCS.md file. 2022-02-27 22:12:20 -08:00

BOSL2

BOSL2 Logo

The Belfry OpenScad Library, v2

A library for OpenSCAD, filled with useful tools, shapes, masks, math and manipulators, designed to make OpenSCAD easier to use.

Requires OpenSCAD 2021.01 or later.

  • NOTE: BOSL2 IS BETA CODE. THE CODE IS STILL BEING REORGANIZED.
  • NOTE2: CODE WRITTEN FOR BOSLv1 PROBABLY WON'T WORK WITH BOSL2!

Join the chat at https://gitter.im/BelfrySCAD/BOSL2

Documentation

You can find the full BOSL2 library documentation at: https://github.com/BelfrySCAD/BOSL2/wiki

Installation

  1. Download the .zip or .tar.gz release file for this library. Currently you should be able to find this at https://github.com/BelfrySCAD/BOSL2/archive/refs/heads/master.zip
  2. Unpack it. Make sure that you unpack the whole file structure. Some zipfile unpackers call this option "Use folder names". It should create either a BOSL-v2.0 or BOSL2-master directory with the library files within it. You should see "examples", "scripts", "tests", and other subdirectories.
  3. Rename the unpacked main directory to BOSL2.
  4. Move the BOSL2 directory into the apropriate OpenSCAD library directory for your platform:
    • Windows: My Documents\OpenSCAD\libraries\
    • Linux: $HOME/.local/share/OpenSCAD/libraries/
    • Mac OS X: $HOME/Documents/OpenSCAD/libraries/
  5. Restart OpenSCAD.

Examples

A lot of the features of this library are to allow shorter, easier-to-read, intent-based coding. For example:

BOSL2/transforms.scad Examples Raw OpenSCAD Equivalent
up(5) translate([0,0,5])
xrot(30,cp=[0,10,20]) translate([0,10,20]) rotate([30,0,0]) translate([0,-10,-20])
xcopies(20,n=3) for (dx=[-20,0,20]) translate([dx,0,0])
zrot_copies(n=6,r=20) for (zr=[0:5]) rotate([0,0,zr*60]) translate([20,0,0])
skew(sxz=0.5,syz=0.333) multmatrix([[1,0,0.5,0],[0,1,0.333,0],[0,0,1,0],[0,0,0,1]])
BOSL2/shapes.scad Examples Raw OpenSCAD Equivalent
cube([10,20,30], anchor=BOTTOM); translate([0,0,15]) cube([10,20,30], center=true);
cuboid([20,20,30], rounding=5); minkowski() {cube([10,10,20], center=true); sphere(r=5, $fn=32);}
prismoid([30,40],[20,30],h=10); hull() {translate([0,0,0.005]) cube([30,40,0.01], center=true); translate([0,0,9.995]) cube([20,30,0.01],center=true);}
xcyl(l=20,d=4); rotate([0,90,0]) cylinder(h=20, d=4, center=true);
cyl(l=100, d=40, rounding=5); minkowski() {cylinder(h=90, d=30, center=true); sphere(r=5);}
tube(od=40,wall=5,h=30); difference() {cylinder(d=40,h=30,center=true); cylinder(d=30,h=31,center=true);}
torus(d_maj=100, d_min=30); rotate_extrude() translate([50,0,0]) circle(d=30);