Packageflash.display
Classpublic final class TriangleCulling
InheritanceTriangleCulling Inheritance Object

Language Version : ActionScript 3.0
Runtime Versions : Flash Player 10, AIR 1.5

Defines codes for culling algorithms that determine which triangles not to render when drawing triangle paths.

The terms POSITIVE and NEGATIVE refer to the sign of a triangle's normal along the z-axis. The normal is a 3D vector that is perpendicular to the surface of the triangle.

A triangle whose vertices 0, 1, and 2 are arranged in a clockwise order has a positive normal value. That is, its normal points in a positive z-axis direction, away from the current view point. When the TriangleCulling.POSITIVE algorithm is used, triangles with positive normals are not rendered. Another term for this is backface culling.

A triangle whose vertices are arranged in a counter-clockwise order has a negative normal value. That is, its normal points in a negative z-axis direction, toward the current view point. When the TriangleCulling.NEGATIVE algorithm is used, triangles with negative normals will not be rendered.

See also

flash.display.Graphics.drawTriangles()
flash.display.GraphicsTrianglePath
to 3D Vectors
Backface Culling


Public Methods
 MethodDefined By
 Inherited
_init():*
[static]
_init
 Inherited
AS3
 Inherited
init():*
[static]
init
 Inherited
AS3
 Inherited
AS3
Protected Methods
 MethodDefined By
 Inherited
[static]
protected
 Inherited
_setPropertyIsEnumerable(o:*, V:String, enumerable:Boolean):void
[static]
protected
Public Constants
 ConstantDefined By
 Inheritedlength : int = 1
[static]
length
  NEGATIVE : String = "negative"
[static] Specifies culling of all triangles facing toward the current view point.
TriangleCulling
  NONE : String = "none"
[static] Specifies no culling.
TriangleCulling
  POSITIVE : String = "positive"
[static] Specifies culling of all triangles facing away from the current view point.
TriangleCulling
Constant Detail
NEGATIVEConstant
public static const NEGATIVE:String = "negative"

Language Version : ActionScript 3.0
Runtime Versions : Flash Player 10, AIR 1.5

Specifies culling of all triangles facing toward the current view point.

NONEConstant 
public static const NONE:String = "none"

Language Version : ActionScript 3.0
Runtime Versions : Flash Player 10, AIR 1.5

Specifies no culling. All triangles in the path are rendered.

POSITIVEConstant 
public static const POSITIVE:String = "positive"

Language Version : ActionScript 3.0
Runtime Versions : Flash Player 10, AIR 1.5

Specifies culling of all triangles facing away from the current view point. This is also known as backface culling.