@realsee/five
Version:
Realsee Renderer SDK
23 lines (22 loc) • 1.02 kB
TypeScript
import { BufferGeometry, BufferAttribute } from 'three';
declare class PointBufferGeometry extends BufferGeometry {
pointCount: number;
/**
* A THREE.BufferGeometry consists of points.
* @param {Number} count The number of points.
*/
constructor(count: number);
bufferPositions(): void;
/**
* Creates a THREE.BufferAttribute on this geometry instance.
*
* @param {String} name Name of the attribute.
* @param {Number} itemSize Number of floats per vertex (typically 1, 2, 3 or 4).
* @param {function=} factory Function that will be called for each point upon creation. Accepts 3 arguments: data[], index and prefabCount. Calls setPointData.
*
* @returns {THREE.BufferAttribute}
*/
createAttribute(name: string, itemSize: number, factory?: (data: any[], index: number, pointCount: number) => void): BufferAttribute;
setPointData(attribute: string | BufferAttribute, pointIndex: number, data: any[]): void;
}
export { PointBufferGeometry };