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-06-19 23:41:39 -04: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 Change $align to align() 2023-06-17 17:42:09 -04:00
.gitignore Improved mkdocspdf.sh 2023-05-08 16:45:38 -07:00
.openscad_docsgen_rc Deprecating metric_screws.scad 2023-06-01 21:44:23 -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 change interior to internal, add default tags for internal 2023-06-19 23:41:39 -04: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 doc fixes 2023-06-18 09:22:41 -04: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 SynTags for attachments.scad to geometry.scad 2023-05-27 01:42:09 -07:00
constants.scad SynTags for attachments.scad to geometry.scad 2023-05-27 01:42:09 -07:00
CONTRIBUTING.md Moving to BelfrySCAD org. 2023-05-21 21:00:05 -07:00
coords.scad SynTags for attachments.scad to geometry.scad 2023-05-27 01:42:09 -07:00
cubetruss.scad SynTags for attachments.scad to geometry.scad 2023-05-27 01:42:09 -07:00
distributors.scad SynTags for attachments.scad to geometry.scad 2023-05-27 01:42:09 -07:00
drawing.scad SynTags for attachments.scad to geometry.scad 2023-05-27 01:42:09 -07:00
fnliterals.scad Synopses, etc for fnliterals.scad 2023-05-02 21:37:03 -07:00
gears.scad change interior to internal, add default tags for internal 2023-06-19 23:41:39 -04:00
geometry.scad SynTags for attachments.scad to geometry.scad 2023-05-27 01:42:09 -07:00
hinges.scad All the SynTags. 2023-05-29 21:48:48 -07:00
joiners.scad All the SynTags. 2023-05-29 21:48:48 -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 All the SynTags. 2023-05-29 21:48:48 -07:00
linear_bearings.scad Deprecating metric_screws.scad 2023-06-01 21:44:23 -07:00
lists.scad All the SynTags. 2023-05-29 21:48:48 -07:00
masks2d.scad SynTags for masks2d, masks3d and partitions 2023-04-14 15:53:35 -07:00
masks3d.scad All the SynTags. 2023-05-29 21:48:48 -07:00
math.scad lookup_vector() -> v_lookup() 2023-05-01 21:49:39 -07:00
metric_screws.scad Deprecating metric_screws.scad 2023-06-01 21:44:23 -07:00
modular_hose.scad All the SynTags. 2023-05-29 21:48:48 -07:00
mutators.scad All the SynTags. 2023-05-29 21:48:48 -07:00
nema_steppers.scad All the SynTags. 2023-05-29 21:48:48 -07:00
partitions.scad All the SynTags. 2023-05-29 21:48:48 -07:00
paths.scad All the SynTags. 2023-05-29 21:48:48 -07:00
polyhedra.scad All the SynTags. 2023-05-29 21:48:48 -07:00
README.md All the SynTags. 2023-05-29 21:48:48 -07:00
regions.scad All the SynTags. 2023-05-29 21:48:48 -07:00
rounding.scad All the SynTags. 2023-05-29 21:48:48 -07:00
screw_drive.scad attachability for torx, roberson, screw_head 2023-06-18 20:20:01 -04:00
screws.scad attachability for torx, roberson, screw_head 2023-06-18 20:20:01 -04:00
shapes2d.scad Shapes2D SynTags 2023-04-14 13:42:53 -07:00
shapes3d.scad All the SynTags. 2023-05-29 21:48:48 -07:00
skin.scad skin.scad docs formatting fixes. 2023-05-31 03:13:04 -07:00
sliders.scad All the SynTags. 2023-05-29 21:48:48 -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 Docs fixes in threading.scad 2023-05-30 21:03:42 -07:00
transforms.scad All the SynTags. 2023-05-29 21:48:48 -07:00
trigonometry.scad Synopses, etc for trigonometry.scad 2023-04-28 18:39:26 -07:00
tripod_mounts.scad All the SynTags. 2023-05-29 21:48:48 -07:00
turtle3d.scad All the SynTags. 2023-05-29 21:48:48 -07:00
utility.scad All the SynTags. 2023-05-29 21:48:48 -07:00
vectors.scad All the SynTags. 2023-05-29 21:48:48 -07:00
version.scad Added Synopses, etc to lists.scad, version.scad, wiring.scad. 2023-03-31 00:20:27 -07:00
vnf.scad All the SynTags. 2023-05-29 21:48:48 -07:00
walls.scad All the SynTags. 2023-05-29 21:48:48 -07:00
wiring.scad All the SynTags. 2023-05-29 21:48:48 -07: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/revarbat/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);