Fix material and geometry types of Points

- Set type for material according to docs
- Make geometry parameter in constructor optional, because three.js provides a default value
- Make geometry type in constructor match one of the class member
This commit is contained in:
SereznoKot
2016-03-30 17:28:19 +03:00
parent fc0f5a34aa
commit 117ecb86cf

10
threejs/three.d.ts vendored
View File

@@ -4539,18 +4539,18 @@ declare namespace THREE {
export class Points extends Object3D {
/**
* @param geometry An instance of Geometry.
* @param geometry An instance of Geometry or BufferGeometry.
* @param material An instance of Material (optional).
*/
constructor(
geometry: Geometry | BufferGeometry,
material?: PointsMaterial | ShaderMaterial
geometry?: Geometry | BufferGeometry,
material?: Material
);
/**
* An instance of Geometry, where each vertex designates the position of a particle in the system.
* An instance of Geometry or BufferGeometry, where each vertex designates the position of a particle in the system.
*/
geometry: Geometry;
geometry: Geometry | BufferGeometry;
/**
* An instance of Material, defining the object's appearance. Default is a PointsMaterial with randomised colour.