Thingiverse
Tube mesh extrusion library for OpenSCAD by arpruss
by Thingiverse
Last crawled date: 3 years ago
This is a library for generating "tube-like" meshes that join a number of cross-sections. For instance, one could use this for a wing profile, or a sphere, or thread.
The cross-sections don't have to planar, nor do they have to have the same number of points, but self-intersection of the resulting tube is likely to be a problem.
There is some optimization done to make triangles in the meshes be closer to equilateral.
One of the cool things one can do with this is "morph" between two plane shapes. For instance,
morphExtrude(ngonPoints(30,d=6), ngonPoints(2,d=4), height=10);
produces a wedge whose bottom is a circle of radius 3, and whose top is a line of length 4, while
morphExtrude([ [0,0], [20,0], [20,10], [0,10] ], [ [ 5,10 ] ], height=20 );
makes a pyramid with a rectangular base.
The main low-level API is the module
tubeMesh(sections,startCap=true,endCap=true,optimize=1)
which takes a vector of three-dimensional counterclockwise cross-sections, and generates a polyhedron. The optimize parameter controls triangle optimization. For smooth twisty things, you might want to increase it to 4 or 5, but for less smooth things, it might screw things up. If you are having problems, set it to 0 or 1.
There is also the higher-level module
morphExtrude(section1,section2=undef,height=undef,numSlices=10,startCap=true,endCap=true,optimize=1,twist=0,curve="t")
This has two modes of operation. If height is undefined, you feed it two three-dimensional sections (if you omit section2, it is the same as section1), and it interpolates between them to generate numSlices layers. If height is defined, you feed it two two-dimensional sections, and interpolation between the two sections separated by the specified height is generated. The twist is mainly for fun.
If you specify the curve parameter, and height is defined, then the interpolation parameter, which normally linearly changes from 0 to 1 with the z coordinate, is transformed according to the function specified by curve. For instance, the pointy pyramid in the demo is done with:
morphExtrude([ [0,0], [20,0], [20,10], [0,10] ], [ [ 10,5 ] ], height=20, curve="sin(90*t)" );
You can use most of the standard OpenSCAD functions and operations for specifying the curve. See here for details. If you want to reference some parameters in your formula, you can add a curveParams=[["paramA",valueA],["paramB",valueB],...] argument to morphExtrude().
If you want access to the points and faces behind tubeMesh(), call pointsAndFaces() with the same arguments. This returns a [points,faces] vector. In fact, tubeMesh() is equivalent to calling polyhedron() with the output of pointsAndFaces().
As a demo, there is a cone() module and a mySphere() module. The latter has the same parameters as the built-in sphere() primitive, but it uses a golden-angle spiral to generate a sphere whose triangles are more uniformly sized than those from the built-in module.
There are also some useful utility functions:
ngonPoints(n=4,r=10,d=undef,rotate=0,z=undef): generate the points of a regular n-gon; 2D unless z is specified
starPoints(n=10,r1=5,r2=10,rotate=0,z=undef): generate the points of a star; 2D unless z is specified
roundedSquarePoints(size=[10,10],radius=2,z=undef): generate the points of a rounded square; 2D unless z is specified
sectionZ(section,z): takes a list of 2D points and add a z-coordinate to them all
shiftSection(section,delta): adds delta to every point in the section list.
Updates:July 8, 2020: Updated to latest eval.scad, fixing pow() bug.May 31, 2020: Optional triangulateEnds argument to allow for ends to be properly triangulated. Added triangulation.scad to project.March 13, 2019: Better mesh optimization for smooth twisting things; twist parameter reversed in direction to match linear_extrude()March 11, 2019: Can omit section2 parameter to morphExtrude().January 14, 2019: Works without the eval.scad library if you don't use the curve parameter. There will be some warnings, but they can be ignored.November 18, 2018: Added curve parameter to morphExtrude().November 21, 2017: Added roundedSquarePoints(), sectionZ() and shiftSection().September 17, 2017: Added tubeMesh() module for convenience.
The cross-sections don't have to planar, nor do they have to have the same number of points, but self-intersection of the resulting tube is likely to be a problem.
There is some optimization done to make triangles in the meshes be closer to equilateral.
One of the cool things one can do with this is "morph" between two plane shapes. For instance,
morphExtrude(ngonPoints(30,d=6), ngonPoints(2,d=4), height=10);
produces a wedge whose bottom is a circle of radius 3, and whose top is a line of length 4, while
morphExtrude([ [0,0], [20,0], [20,10], [0,10] ], [ [ 5,10 ] ], height=20 );
makes a pyramid with a rectangular base.
The main low-level API is the module
tubeMesh(sections,startCap=true,endCap=true,optimize=1)
which takes a vector of three-dimensional counterclockwise cross-sections, and generates a polyhedron. The optimize parameter controls triangle optimization. For smooth twisty things, you might want to increase it to 4 or 5, but for less smooth things, it might screw things up. If you are having problems, set it to 0 or 1.
There is also the higher-level module
morphExtrude(section1,section2=undef,height=undef,numSlices=10,startCap=true,endCap=true,optimize=1,twist=0,curve="t")
This has two modes of operation. If height is undefined, you feed it two three-dimensional sections (if you omit section2, it is the same as section1), and it interpolates between them to generate numSlices layers. If height is defined, you feed it two two-dimensional sections, and interpolation between the two sections separated by the specified height is generated. The twist is mainly for fun.
If you specify the curve parameter, and height is defined, then the interpolation parameter, which normally linearly changes from 0 to 1 with the z coordinate, is transformed according to the function specified by curve. For instance, the pointy pyramid in the demo is done with:
morphExtrude([ [0,0], [20,0], [20,10], [0,10] ], [ [ 10,5 ] ], height=20, curve="sin(90*t)" );
You can use most of the standard OpenSCAD functions and operations for specifying the curve. See here for details. If you want to reference some parameters in your formula, you can add a curveParams=[["paramA",valueA],["paramB",valueB],...] argument to morphExtrude().
If you want access to the points and faces behind tubeMesh(), call pointsAndFaces() with the same arguments. This returns a [points,faces] vector. In fact, tubeMesh() is equivalent to calling polyhedron() with the output of pointsAndFaces().
As a demo, there is a cone() module and a mySphere() module. The latter has the same parameters as the built-in sphere() primitive, but it uses a golden-angle spiral to generate a sphere whose triangles are more uniformly sized than those from the built-in module.
There are also some useful utility functions:
ngonPoints(n=4,r=10,d=undef,rotate=0,z=undef): generate the points of a regular n-gon; 2D unless z is specified
starPoints(n=10,r1=5,r2=10,rotate=0,z=undef): generate the points of a star; 2D unless z is specified
roundedSquarePoints(size=[10,10],radius=2,z=undef): generate the points of a rounded square; 2D unless z is specified
sectionZ(section,z): takes a list of 2D points and add a z-coordinate to them all
shiftSection(section,delta): adds delta to every point in the section list.
Updates:July 8, 2020: Updated to latest eval.scad, fixing pow() bug.May 31, 2020: Optional triangulateEnds argument to allow for ends to be properly triangulated. Added triangulation.scad to project.March 13, 2019: Better mesh optimization for smooth twisting things; twist parameter reversed in direction to match linear_extrude()March 11, 2019: Can omit section2 parameter to morphExtrude().January 14, 2019: Works without the eval.scad library if you don't use the curve parameter. There will be some warnings, but they can be ignored.November 18, 2018: Added curve parameter to morphExtrude().November 21, 2017: Added roundedSquarePoints(), sectionZ() and shiftSection().September 17, 2017: Added tubeMesh() module for convenience.
Similar models
thingiverse
free
Bevel Extrude Module for OpenSCAD by GregFrost
...h (how low the bevel is cut into the top of the extruded object).
$fn = (number of facets on curved bevels of concave corners).
thingiverse
free
Bezier Library for OpenScad by ckirby
...ts".
at the moment, there is no documentation! but there is a test file that runs through most of the available features.
thingiverse
free
Twisted Vase Generator by DanielKolz
...y some parameters:
layer resolution
bottom thickness
wall- thickness
twist
count of corners (min. 3)
radius and height of object
thingiverse
free
Customisable bezier low-poly vase by bdbbdb
...ezier curves are very strange (loops, non-smooth), not all combinaisons have been tested and some might give you strange designs.
thingiverse
free
Knot-style Parametric Function Script ( Python ) by mrule
...at the top and adds a couple integer parameters, similar too...
thingiverse
free
openscad triangle generator by postcoital_mass
... and it's b side will be placed on y axis for make easy rotate_extrude() calculations. list of usable formulas shown near eof
thingiverse
free
Cylindrical Functions Script by mrule
.... if a .scad filename is given as the command line argument, an openscad script will be written and meshlab will not be launched.
grabcad
free
Lathe cutting tool
...asa system. it can be easily modified to desired tool geometry by specifying the parameters in the "equations" section.
thingiverse
free
Exact Gear Path Generator by gringer
...ng herringbone "inner" and "outer" gears is provided to demonstrate the power of a path-based gear generator.
thingiverse
free
Spiral vase / bowl customizer by jamcultur
...on a potterbot, or other 3d printer whose slicer needs a solid object, specify base thickness the same as the height of the vase.
Arpruss
thingiverse
free
Watch band part by arpruss
...watch band part by arpruss
thingiverse
my son needed this.
thingiverse
free
Smiley face stencil by arpruss
...smiley face stencil by arpruss
thingiverse
simple smiley face stencil.
thingiverse
free
Folding chair foot by arpruss
...folding chair foot by arpruss
thingiverse
quick and dirty folding chair foot. customizable.
thingiverse
free
Customizable hex maze by arpruss
...customizable hex maze by arpruss
thingiverse
generates a hex-cell maze using recursive backtracking.
thingiverse
free
Customizable cable clip by arpruss
...ustomizable cable clip by arpruss
thingiverse
this is a simple customizable cable clip.
this uses and bundles my bezier library.
thingiverse
free
Customizable unicorn horn by arpruss
...ingiverse
customize twist, rounding, height, diameter and number of lobes.
uses (and bundles) my tube mesh and bezier libraries.
thingiverse
free
Wooden railway bridge support by arpruss
...wooden railway bridge support by arpruss
thingiverse
yet another support for brio-style wooden railroad bridges. customizable.
thingiverse
free
Saturn cookie cutter by arpruss
...tter was generated with inkscape and some plugins. instructions on how to do this are here. you can customize various dimensions.
thingiverse
free
Randomized leafy snowflake by arpruss
...domized snowflake generator for blockscad (with an openscad-based customizer exported from it, and variables moved to beginning).
thingiverse
free
Smiley face by arpruss
...inflation scripts. there is a positive version where the eyes and mouth stick out, and a negative version where they are cut out.
Extrusion
turbosquid
free
aluminum extrusion profiles
...free 3d model aluminum extrusion profiles for download as max on turbosquid: 3d models for games, architecture, videos. (1381707)
turbosquid
$5
Cable Cover Extrusion
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
3d_export
free
30 x 30 extrusion
... x 30 x 40.sldprt<br>30 x 30 x 50.sldprt<br>30 x 30 x 606.sldprt<br>the sketch.sldprt<br>30 x 30 x 40.stl
3d_export
$300
melt-blown fabric extrusion molding machine
...an email to me.<br>designed with solidworks 2017, render with photoview 360<br>**************************************
3d_export
$5
Spaceship - Galaxy Crusher
...with a more ominous twist. it has lots of extrusion and cubes and comes with a whopping 4k texture,...
3d_export
$20
1600 Meltblown cloth production line set drawing CAD
...width of 1600mm. the steel structure frame, feeding host, extrusion screw, heating system, screen changer, metering pump, melting it...
3d_export
$5
one-eyed scary virus
...cinema, the body relief is formed by the standard extrusion noise. the eye texture is...
3d_export
$20
GE TF34 Fan Blade and Nose Cone
...and appropriately sized fillet features are provided.<br>also, a threaded extrusion profile is provided on the fan blade component and...
3d_export
$10
glue injection machine
...injection technology. the ordinary glue injection machine is screw extrusion type, and its instantaneous pressure can reach more than...
3d_export
$1000
bead triangle adhesive laminating machine
...a triangular rubber head with the shape required for extrusion the rear end of the extruder is also provided...
Openscad
thingiverse
free
OpenSCAD sphere
...openscad sphere
thingiverse
basic project for openscad.
thingiverse
free
Openscad Football by KySyth
...openscad football by kysyth
thingiverse
openscad not tested
thingiverse
free
Openscad Apple by KySyth
...openscad apple by kysyth
thingiverse
openscad apple = not tested
thingiverse
free
Plugs with openscad by benengel
...plugs with openscad by benengel
thingiverse
plugs with openscad and fontawesome
thingiverse
free
Openscad spirals by mafmuf
...openscad spirals by mafmuf
thingiverse
just fooling around with openscad.
thingiverse
free
Practice on OpenScad by ajensen906
...practice on openscad by ajensen906
thingiverse
a very crude practice on openscad
thingiverse
free
Batteries in OpenSCAD by roman_hegglin
...batteries in openscad by roman_hegglin
thingiverse
common batteries as modules for openscad.
thingiverse
free
OpenScad Propeller by KySyth
...se
trying to make a propeller with openscad = not tested
this is some of the results
added the openscad file but still need work
thingiverse
free
Openscad Cloud by Twanne
...openscad cloud by twanne
thingiverse
openscad cloud.
size can be adjusted
thingiverse
free
Geomag for OpenScad by vicnet
...geomag for openscad by vicnet
thingiverse
openscad file to design geomag things.
Tube
archibase_planet
free
Tube
...tube
archibase planet
paint tube stationery
tube - 3d model (*.gsm+*.3ds) for interior 3d visualization.
turbosquid
free
tube
...tube
turbosquid
free 3d model tube for download as c4d on turbosquid: 3d models for games, architecture, videos. (1378271)
archibase_planet
free
Tube
...tube
archibase planet
mascara cosmetics make-up
tube 1 - 3d model (*.gsm+*.3ds) for interior 3d visualization.
3d_export
$5
Tube pants
...tube pants
3dexport
tube pants
3d_export
free
Tube
...tube
3dexport
turbosquid
free
TUBE
...
free 3d model tube for download as blend, dae, fbx, and obj on turbosquid: 3d models for games, architecture, videos. (1672199)
turbosquid
$29
tube
...lty free 3d model tube for download as 3ds, obj, c4d, and fbx on turbosquid: 3d models for games, architecture, videos. (1442047)
3ddd
$1
perfume tube
...perfume tube
3ddd
тюбик
perfume tube, тюбик
3ddd
$1
Olivieri Tube
...olivieri tube
3ddd
olivieri
кровать olivieri tube
turbosquid
$22
Tube
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
Library
3d_ocean
$5
Library
...library
3docean
book book case library
library
3d_export
$6
library
...library
3dexport
a ready-made model of a library for use in peru
3d_ocean
$5
Library
...library
3docean
book books furniture home home design interior library
home design…
turbosquid
$15
library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1351741)
turbosquid
$9
Library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1433110)
turbosquid
$7
Library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1363568)
turbosquid
$5
Library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1309343)
3ddd
$1
classic library
...classic library
3ddd
library
classic library
3dsmax 2008 vray
3d_export
$10
Library
...library
3dexport
3d_export
free
library
...library
3dexport
Mesh
design_connected
$16
Mesh
...mesh
designconnected
jaipur living mesh computer generated 3d model.
design_connected
$13
Mesh
...mesh
designconnected
luceplan mesh computer generated 3d model. designed by gomez paz, francisco.
turbosquid
$29
mesh
...lty free 3d model mesh for download as 3ds, obj, c4d, and fbx on turbosquid: 3d models for games, architecture, videos. (1361487)
turbosquid
$1
mesh
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
3d_export
$5
mesh fence
...mesh fence
3dexport
metal mesh fence
3d_export
$5
hexagonal mesh
...hexagonal mesh
3dexport
3d model of hexagoal mesh
3d_export
$5
shelf mesh
...shelf mesh
3dexport
shelf mesh kare design
3ddd
free
mesh chair
...mesh chair
3ddd
стул
оффисное кресло mesh chair
3d_ocean
$8
Monkey mesh
...monkey mesh
3docean
animal hand monkey shoes tail
this is a low poly mesh of a cartoon monkey mesh. i hope you enjoy this model.
3d_ocean
$2
Wire mesh
...sire aspect. the model has materials applied and is ready to render in both formats(obj/blend). the mesh can be cut or expande...