Packageaway3d.core.base
Classpublic class Face
InheritanceFace Inheritance Element

A triangle element used in the mesh object

See also

away3d.core.base.Mesh
Public Properties
 PropertyDefined by
  back : Material
Defines the optional back material of the face.
Face
  bitmapRect : Rectangle
Face
 Inheritedcommands : Vector
Returns an array of drawing command strings that make up the 3d element.
Element
 Inheritedextra : Object
An optional untyped object that can contain used-defined properties.
Element
  faceVO : FaceVO
Face
  isBack : Boolean
Face
  material : Material
Defines the material of the face.
Face
 Inheritedparent : Geometry
Defines the parent 3d object of the segment.
Element
 InheritedpathCommands : Array
Returns an array of drawing command objects that are used by the face.
Element
 Inheriteduvs : Vector
Returns an array of uv objects that are used by the element.
Element
 Inheritedvertices : Vector
Returns an array of vertex objects that make up the 3d element.
Element
 Inheritedvisible : Boolean
Determines whether the 3d element is visible in the scene.
Element
Protected Properties
 PropertyDefined by
 Inherited_commands : Vector
Element
 Inherited_lastAddedVertex : Vertex
Element
 Inherited_material : Material
Element
 Inherited_pathCommands : Array
Element
 Inherited_uvs : Vector
Element
 Inherited_vertices : Vector
Element
Public Methods
 MethodDefined by
  
Face
(v0:Vertex = null, v1:Vertex = null, v2:Vertex = null, material:Material = null, uv0:UV = null, uv1:UV = null, uv2:UV = null)
Creates a new Face object.
Face
  
addUVAt(index:uint, uv:UV):void
Face
  
addVertexAt(index:uint, vertex:Vertex, command:String):void
Face
  
Produces a clone of the face.
Face
  
curveTo(cx:Number, cy:Number, cz:Number, ex:Number, ey:Number, ez:Number):void
Face
  
invert():void
Inverts the geometry of the face object by swapping the v1, v2 and uv1, uv2 points.
Face
  
lineTo(x:Number, y:Number, z:Number):void
Face
  
moveTo(x:Number, y:Number, z:Number):void
Face
Property detail
backproperty
back:Material  [read-write]

Defines the optional back material of the face. Displays when the face is pointing away from the camera.

Implementation
    public function get back():Material
    public function set back(value:Material):void
bitmapRectproperty 
public var bitmapRect:Rectangle
faceVOproperty 
public var faceVO:FaceVO
isBackproperty 
public var isBack:Boolean
materialproperty 
material:Material  [read-write]

Defines the material of the face.

Implementation
    public function get material():Material
    public function set material(value:Material):void
Constructor detail
Face()constructor
public function Face(v0:Vertex = null, v1:Vertex = null, v2:Vertex = null, material:Material = null, uv0:UV = null, uv1:UV = null, uv2:UV = null)Parameters
v0:Vertex (default = null) — The first vertex object of the triangle
 
v1:Vertex (default = null) — The second vertex object of the triangle
 
v2:Vertex (default = null) — The third vertex object of the triangle
 
material:Material (default = null) — [optional] The material used by the triangle to render
 
uv0:UV (default = null) — [optional] The first uv object of the triangle
 
uv1:UV (default = null) — [optional] The second uv object of the triangle
 
uv2:UV (default = null) — [optional] The third uv object of the triangle
Init Parameters

See also

Method detail
addUVAt()method
public function addUVAt(index:uint, uv:UV):void Parameters
index:uint
 
uv:UV
addVertexAt()method 
public function addVertexAt(index:uint, vertex:Vertex, command:String):void Parameters
index:uint
 
vertex:Vertex
 
command:String
clone()method 
public function clone():Face

Produces a clone of the face. NOTE: Supports only irregular faces for now.

Returns
Face — [Face] The cloned face.
curveTo()method 
public function curveTo(cx:Number, cy:Number, cz:Number, ex:Number, ey:Number, ez:Number):void Parameters
cx:Number
 
cy:Number
 
cz:Number
 
ex:Number
 
ey:Number
 
ez:Number
invert()method 
public function invert():void

Inverts the geometry of the face object by swapping the v1, v2 and uv1, uv2 points.

lineTo()method 
public function lineTo(x:Number, y:Number, z:Number):void Parameters
x:Number
 
y:Number
 
z:Number
moveTo()method 
public function moveTo(x:Number, y:Number, z:Number):void Parameters
x:Number
 
y:Number
 
z:Number
Wiki link
Click to go to the wiki page for 'away3d.core.base.Face'

Code examples

Comments