public class Cylinder extends Atomic3dModel
Abstract3dModel
,
which means you can use the convenient methods on cylinders too.Modifier and Type | Field and Description |
---|---|
protected Radius |
bottomRadius |
protected double |
length |
protected Radius |
topRadius |
Constructor and Description |
---|
Cylinder(double length,
double r)
Deprecated.
use the constructor with Radius parameters instead of doubles
|
Cylinder(double length,
double bottomRadius,
double topRadius)
Deprecated.
use the constructor with Radius parameters instead of doubles
|
Cylinder(double length,
Radius r)
Creates a cylinder with a given length and radius.
|
Cylinder(double length,
Radius bottomRadius,
Radius topRadius)
Creates a truncated cone.
|
Modifier and Type | Method and Description |
---|---|
protected Boundaries3d |
getModelBoundaries() |
protected Abstract3dModel |
innerCloneModel() |
protected SCAD |
innerToScad(IColorGenerationContext context)
Generates the OpenSCAD representation of the model without.
|
protected CSG |
toInnerCSG(FacetGenerationContext context) |
getChildrenModels, innerSubModel, isPrimitive
addModel, addModelTo, align, align, align, align, align, annotate, background, cloneModel, debug, findAnnotatedModel, getBoundaries, getTag, isBackground, isDebug, isMoved, isRotated, move, moves, moves, moves, moves, rotate, rotates, rotates, round, subModel, subtractModel, toCSG, toCSG, toScad, withTag
protected final double length
protected final Radius bottomRadius
protected final Radius topRadius
public Cylinder(double length, Radius bottomRadius, Radius topRadius) throws IllegalValueException
length
- the length of the cylinderbottomRadius
- the bottom radius of the cylindertopRadius
- the top radius of the cylinderIllegalValueException
- if the length or any any of the two radius parameter is negativepublic Cylinder(double length, Radius r) throws IllegalValueException
length
- the length of the cylinderr
- the radius of the cylinderIllegalValueException
- if the length or the radius parameter is negative@Deprecated public Cylinder(double length, double bottomRadius, double topRadius) throws IllegalValueException
length
- the length of the cylinderbottomRadius
- the bottom radius of the cylindertopRadius
- the top radius of the cylinderIllegalValueException
- if the length or any any of the two radius parameter is negative@Deprecated public Cylinder(double length, double r) throws IllegalValueException
length
- the length of the cylinderr
- the radius of the cylinderIllegalValueException
- if the length or the radius parameter is negativeprotected SCAD innerToScad(IColorGenerationContext context)
Abstract3dModel
innerToScad
in class Abstract3dModel
protected Boundaries3d getModelBoundaries()
getModelBoundaries
in class Abstract3dModel
protected Abstract3dModel innerCloneModel()
innerCloneModel
in class Abstract3dModel
protected CSG toInnerCSG(FacetGenerationContext context)
toInnerCSG
in class Abstract3dModel
Copyright © 2014–2020, Printing in 3D. All rights reserved.