The already mentioned poly parameter is always required when present. Included by alternatives_spheres.scad webbing.scad Implements "webbing" function which is a way to connect two separate circles with a smooth transition to a thin section between them.Īll functions here are intended to behave identically to their OpenSCAD builtin counterparts, however some may have additional parameters. subdivision.scad Provides subdivision function which splits each triangle in a 3D poly into 4 smaller triangles by adding midpoints. planes.scad Functions relating to geometric planes. double_fillet.scad Provides double_fillet function which generates a smooth transition between two parallel surfaces. All functions that implement OpenSCAD builtins are contained in this file, plus a few utilities and extrasĪlternative_spheres.scad Alternative implementations of spherical geometries, using different methods of tesselation, (eg. API Reference Library Files functional.scad The core of FunctionalOpenSCAD. Therefore we must pass our poly data as the last parameter for all Transformation functions, etc. In OpenSCAD, functions can not have or interact with Depending on how it is used, it may represent a 2D polygon, or some partial path that will later be concatenated with other paths to form a whole polygon, etc.Īdditionally, a poly may represent a "poly vector" (list of polys), which most functions will also accept: Functions that operation on existing shapes (eg transformations) always take poly as the last parameter, and return a poly. It's just some nested lists(or " vectors") that we can interpret as shapes or vertices.įunctions for the geometric primitives always return a poly. I use quotations around "datatype" because OpenSCAD does not have user-defined types. It is called this because it can represent either a polygon or polyhedron. The functions in this library operate on geometric data in a special format which we call a poly. Since the call to square above is not stored in a variable or passed as parameter, OpenSCAD knows to use the builtin square module. The OpenSCAD language keeps separate namespaces for functions and modules, and distinguishes between the two based on syntax and context. The functions in this library have the same names as the builtin OpenSCAD modules that they emulate,īut that doesn't mean the builtins are overriden. If you need a introduction / refresher to these concepts. To understand what this library is doing, its important to note the distinction between functions and modules in OpenSCAD. This sort of calculation is not possible when using builtin modules because their vertex data is not accessible. Representing the max and min coordinates of all points that make up a shape or list of shapes To extend the functionality of OpenSCAD from within a user script.įor example, this library includes function bounds(poly) which returns ,] Having access to vertex, path, and face geometry data makes it possible This library is an attempt to re-implement OpenSCAD's builtin modulesĪs functions which operate directly on vertex data. Implementing OpenSCAD in OpenSCAD Introduction
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |