Copy this cell by completely copying internal data structures.
Argument
Type
Required
Description
cell
vtkCell
Yes
The cell you want to use.
extend
Method used to decorate a given object (publicAPI+model) with vtkCell characteristics.
Argument
Type
Required
Description
publicAPI
Yes
object on which methods will be bounds (public)
model
Yes
object on which data structure will be bounds (protected)
initialValues
ICellInitialValues
No
(default: {})
getBounds
Get the bounds for this mapper as [xmin, xmax, ymin, ymax,zmin, zmax].
getLength2
Compute Length squared of cell (i.e., bounding box diagonal squared).
getNumberOfPoints
Get the number of points in the cell.
getParametricDistance
Get the distance of the parametric coordinate provided to the cell. If inside the cell, a distance of zero is returned. This is used during picking to get the correct cell picked. (The tolerance will occasionally allow cells to be picked who are not really intersected “inside” the cell.)
Argument
Type
Required
Description
pcoords
Vector3
Yes
The coordinates of the point.
getPoints
getPointsIds
initialize
Initialize the cell with point coordinates and cell point ids, example :
If pointIdsList is null, points are shallow copied and pointIdsList is generated as such: [0, 1, …, N-1] where N is the number of points. If pointIdsList is not null, only pointIdsList point coordinates are copied into the cell. pointIdsList is shallow copied.
export interface vtkCell extends vtkObject { /** * Copy this cell by completely copying internal data structures. * @param {vtkCell} cell The cell you want to use. */ deepCopy(cell: vtkCell): void;
/** * Initialize the cell with point coordinates and cell point ids, example : * * ```js * const points = vtkPoints.newInstance(); * points.setData(Float32Array.from([0, 0, 0, 0, 0, 1, ..., 255, 255, 255])); * const pointIdsList = [13, 10, 235]; * // Create cell * const triangle = vtkTriangle.newInstance(); * // Initialize cell * triangle.initialize(points, pointIdsList); * ``` * * If pointIdsList is null, points are shallow copied and pointIdsList is * generated as such: [0, 1, ..., N-1] where N is the number of points. If * pointIdsList is not null, only pointIdsList point coordinates are copied into * the cell. pointIdsList is shallow copied. * @param {vtkPoints} points * @param {Number[]} [pointIdsList] */ initialize(points: vtkPoints, pointIdsList?: number[]): void;
/** * Get the bounds for this mapper as [xmin, xmax, ymin, ymax,zmin, zmax]. * @return {Bounds} The bounds for the mapper. */ getBounds(): Bounds;
/** * Get the distance of the parametric coordinate provided to the cell. If * inside the cell, a distance of zero is returned. This is used during * picking to get the correct cell picked. (The tolerance will occasionally * allow cells to be picked who are not really intersected "inside" the * cell.) * @param {Vector3} pcoords The coordinates of the point. * */ getParametricDistance(pcoords: Vector3): number;
/** * */ getPoints(): vtkPoints;
/** * */ getPointsIds(): number[];
/** * Get the number of points in the cell. */ getNumberOfPoints(): number;
/** * Method used to decorate a given object (publicAPI+model) with vtkCell characteristics. * * @param publicAPI object on which methods will be bounds (public) * @param model object on which data structure will be bounds (protected) * @param {ICellInitialValues} [initialValues] (default: {}) */ exportfunctionextend( publicAPI: object, model: object, initialValues?: ICellInitialValues ): void;
/** * Method used to create a new instance of vtkCell. * @param {ICellInitialValues} [initialValues] for pre-setting some of its content */ exportfunctionnewInstance(initialValues?: ICellInitialValues): vtkCell;
/** * vtkCell is an abstract method to define a cell */ export declare constvtkCell: { newInstance: typeof newInstance; extend: typeof extend; }; exportdefault vtkCell;