Skip to content

ConcentricCylinderSource ​

Introduction ​

vtkConcentricCylinderSource creates a set of concentric cylinders sharing the same axis. Each layer is defined by its radius and can carry its own cell field value, which is stored in the layer cell array of the output polydata. Layers can individually be hidden with a mask, and the faces shared by two visible layers can be skipped.

Usage ​

js
import vtkConcentricCylinderSource from '@kitware/vtk.js/Filters/Sources/ConcentricCylinderSource';

const cylinder = vtkConcentricCylinderSource.newInstance({
  height: 2,
  radius: [0.5, 1, 2],
  cellFields: [0, 1, 2],
});
const polydata = cylinder.getOutputData();

Methods ​

addRadius ​

Add a new layer with the given radius. When no cell field is provided, the index of the new layer is used.

ArgumentTypeRequiredDescription
radiusNumberYes
cellFieldNumberNo

clearRadius ​

Remove every layer along with their cell fields.

extend ​

Method used to decorate a given object (publicAPI+model) with vtkConcentricCylinderSource characteristics.

ArgumentTypeRequiredDescription
publicAPIYesobject on which methods will be bounds (public)
modelYesobject on which data structure will be bounds (protected)
initialValuesIConcentricCylinderSourceInitialValuesNo(default: {})

getCellFields ​

Get the cell field value of each layer.

getCellFieldsByReference ​

Get the cell field value of each layer.

getCenter ​

Get the center of the cylinder.

getCenterByReference ​

Get the center of the cylinder.

getDirection ​

Get the orientation vector of the cylinder.

getDirectionByReference ​

Get the orientation vector of the cylinder.

getEndTheta ​

Get the angular sector ending angle in degrees.

getHeight ​

Get the height of the cylinder.

getMaskLayer ​

Get whether the given layer is hidden.

ArgumentTypeRequiredDescription
indexNumberYes

getMaskLayer ​

Get the full hidden-layer mask, or null when no mask is set.

getNumberOfRadius ​

Get the number of layers.

getRadius ​

Get the radius of the given layer.

ArgumentTypeRequiredDescription
indexNumberNo(default: 0)

getResolution ​

Get the number of facets used to represent each cylinder.

getSkipInnerFaces ​

Get whether the faces shared by two visible layers are skipped.

getStartTheta ​

Get the angular sector starting angle in degrees.

newInstance ​

Method used to create a new instance of vtkConcentricCylinderSource.

ArgumentTypeRequiredDescription
initialValuesIConcentricCylinderSourceInitialValuesNofor pre-setting some of its content

removeMask ​

Clear the hidden-layer mask so that every layer is visible.

requestData ​

Expose methods

ArgumentTypeRequiredDescription
inDataYes
outDataYes

setCellField ​

Set the cell field value of the given layer.

ArgumentTypeRequiredDescription
indexNumberYes
fieldNumberYes

setCenter ​

Set the center of the cylinder.

ArgumentTypeRequiredDescription
centerVector3Yes

setCenter ​

Set the center of the cylinder.

ArgumentTypeRequiredDescription
xNumberYesThe x coordinate.
yNumberYesThe y coordinate.
zNumberYesThe z coordinate.

setCenterFrom ​

Set the center of the cylinder.

ArgumentTypeRequiredDescription
centerVector3Yes

setDirection ​

Set the direction for the cylinder.

ArgumentTypeRequiredDescription
directionVector3Yes

setDirection ​

Set the direction for the cylinder.

ArgumentTypeRequiredDescription
xNumberYesThe x coordinate.
yNumberYesThe y coordinate.
zNumberYesThe z coordinate.

setDirectionFrom ​

Set the direction for the cylinder.

ArgumentTypeRequiredDescription
directionVector3Yes

setEndTheta ​

Set the angular sector ending angle in degrees.

ArgumentTypeRequiredDescription
endThetaNumberYes

setHeight ​

Set the height of the cylinder.

ArgumentTypeRequiredDescription
heightNumberYes

setMaskLayer ​

Hide or show the given layer.

ArgumentTypeRequiredDescription
indexNumberYes
hiddenBooleanYes

setRadius ​

Set the radius of an already existing layer.

ArgumentTypeRequiredDescription
indexNumberYes
radiusNumberYes

setResolution ​

Set the number of facets used to represent each cylinder.

ArgumentTypeRequiredDescription
resolutionNumberYes

setSkipInnerFaces ​

Turn on/off the generation of the faces that are shared by two consecutive visible layers.

ArgumentTypeRequiredDescription
skipInnerFacesBooleanYes

setStartTheta ​

Set the angular sector starting angle in degrees.

ArgumentTypeRequiredDescription
startThetaNumberYes