Repository

OutlineMesh

Extends:

Mesh → OutlineMesh

OutlineMesh class creates a hiddenline fashioned Mesh from any other Mesh.

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public
public
public
Private Members
private

_mesh: *

Inherited Summary

From class Mesh
public static

generateStrokeMesh(mesh: Mesh, inflateValue: Number): Mesh

Static Utils to generate the stroke Mesh from a given shape

public static

Static Utils to generate the stroke Mesh from a given shape

public static

generateStrokeShape(mesh: Mesh, inflateValue: Number): *

Static Utils to generate the stroke for the given vertices with the given stroke width

public static

geometryIsCW(geometry: Geometry): Boolean

Static Utils to check the direction of a geometry (ccw o cw)

public

events: *

public
public
public

name: *

public
public
public

type: *

private

_mesh: *

public

Attach the material to this mesh.

public

Clears this mesh's geometry, that is vertices, faces and faceVertexUvs

public

clone(): *

deep clone this Mesh return {Mesh} a new clone (copy) of this Mesh in a new Mesh object

public

compute Face and Vertex Normals for the current geometry

public

Call this method to construct a custom mesh

public

Erase this mesh's geometry and material from memory

public

generateFillMesh(vertices: *)

Generate the mesh for the given vertices and generates flat uvs for it.

public

Generate the flat uvs for this mesh.

public

genereate a mesh from already made geometry and material

public

Compute and returns the bounding box of the current geometry or Node, which is an object made of 2 Vector3.

public

Compute and returns the bounding sphere of the current geometry or Node, which is an object with a radius :

public

Returns the center of the geometry (vertices) based on boundingbox

public

Compute the intersection points between a plane and a mesh !Works ONLY if this mesh is "plane" primitive made

public
public
public

Returns the size of the geometry (vertices) based on boundingbox

public

getUVs(index: integer): Array

Get the UV of this mesh geometry

public

Get the vertexColors of this mesh geometry's vertices

public

Get the vertices of this mesh geometry

public

Get the visibility of this mesh

public

pushFace(i1: Integer, i2: Integer, i3: Integer): *

Adds a face to the current geometry

public

Adds a UV to the current geometry

public

pushQuad(v1: Vector3, v2: Vector3, v3: Vector3, v4: Vector3, uv1: Vector2, uv2: Vector2, uv3: Vector2, uv3: Vector2)

Adds a Quad to the current geometry

public

Adds a triangle to the current geometry

public

pushUV(uv1: Vector2, uv2: Vector2, uv3: Vector2)

Adds a UV to the current geometry

public

Adds a vertex to the current geometry

public

convinient method to reverse this Mesh geometry's normals

public

setCastShadow

public

Defines the position of the geometry's center (NOT the transform!).

public

setEventEmitterTrigger(scope: *, eventType: *)

public

setFaces(faces: *)

public

Sets this Mesh material.

public

setReceiveShadow

public
public

setRotationX(value: float)

Set the rotation around x axis of the vertices (not the transform!)

public

setRotationY(value: float)

Set the rotation around y axis of the vertices (not the transform!)

public

setRotationZ(value: float)

Set the rotation around z axis of the vertices (not the transform!)

public

setScale(number|Vector3|Vector2: float | Vector3 | Vector2, Number: float, Number: float)

Set the scale of the geometry (vertices) - this is not like scaling the transform.

public

setTranslation(value: float, value: float, value: float)

Set the translation along all axis of the vertices (not the transform!)

public

setUVs(index: integer, uvs: Array)

Set the UV of this mesh geometry

public

Set the vertexColors of this mesh geometry's vertices

public

setVertices(vertices: Object)

Set the vertices of this mesh geometry

public

Set the visibility of this mesh

public

updateMesh

public

updateStroke(inflateValue: Number)

Utils to regenerate the stroke Mesh when already existing

private

getUVFromIntersectionPoint

private

setPointOfIntersection(line: Object, plane: Object, intersectionPoint: Object): Object

setPointOfIntersection

private

Updates this mesh material

Public Constructors

public constructor(params: Object) source

Construct an empty and unfinished Mesh for which a geometry must be constructed. Once filled with vertices, constructMesh method must be called, or a method generating a complete Mesh must be used (i.e generateFillMesh)

Override:

Mesh#constructor

Params:

NameTypeAttributeDescription
paramsObject

parameters this can contains the same parameters than Mesh class

params.inputMeshMesh

The existing Mesh to use for generate a new edge only Mesh (geometry and material)

Public Members

public inputMesh: * source

public material: * source

Override:

Mesh#material

public transform: * source

Override:

Mesh#transform

Private Members

private _mesh: * source

Override:

Mesh#_mesh