[name]

Contains handy functions geometry manipulations.

Methods

.merge( [page:Geometry geometry1] , [page:Geometry geometry2], [page:Integer materialIndexOffset] )

geometry1 — Parent geomentry element
geometry2 — Geometry that need to be added in parent
materialIndexOffset — Offset applied to the materialIndex of all the new faces in the merged geometry. Default : 0

.randomPointInTriangle( [page:Vector VectorA] , [page:Vector VectorB] , [page:Vector VectorC])

VectorA — Vector
VectorB — Vector
VectorC — Vector
returns [page:Int Point]

.randomPointInFace( [page:face Face] , [page:geometry Geometry] , [page:Boolean useCachedAreas])

Face — Face id
Geometry — Geometry that contains the Face
useCachedAreas — Flag to use cached areas. Default : False
returns [page:Int Point]

.randomPointsInGeometry( [page:geometry Geometry] , [page:Integer Points])

Geometry — Geometry
returns [page:Int Point]

.triangleArea ( [page:Vector VectorA] , [page:Vector VectorB] , [page:Vector VectorC])

VectorA — Vector
VectorB — Vector
VectorC — Vector
returns [page:Int Area]

.center ( [page:geometry Geometry] )

Geometry — Geometry to Center position

.triangulateQuads ( [page:geometry Geometry] )

Geometry — Geometry to triangulate Quads

Source

[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]