| Package | away3d.core.draw |
| Class | public class DrawTriangle |
| Inheritance | DrawTriangle DrawPrimitive |
| Property | Defined by | ||
|---|---|---|---|
| area : Number
The calulated area of the triangle primitive.
| DrawTriangle | ||
| backface : Boolean = false
Indicates whether the face of the triangle primitive is facing away from the camera.
| DrawTriangle | ||
![]() | create : Function
Placeholder function for creating new drawing primitives from a cache of objects.
| DrawPrimitive | |
| face : Face
A reference to the face object used by the triangle primitive.
| DrawTriangle | ||
| invtexturemapping : Matrix
The inverse texturemapping matrix of the triangle primitive texture.
| DrawTriangle | ||
| material : ITriangleMaterial
The bitmapData object used as the triangle primitive texture.
| DrawTriangle | ||
![]() | maxX : Number
Indicates the maximum x value of the drawing primitive.
| DrawPrimitive | |
![]() | maxY : Number
Indicates the maximum y value of the drawing primitive.
| DrawPrimitive | |
![]() | maxZ : Number
Indicates the maximum z value of the drawing primitive.
| DrawPrimitive | |
![]() | minX : Number
Indicates the minimum x value of the drawing primitive.
| DrawPrimitive | |
![]() | minY : Number
Indicates the minimum y value of the drawing primitive.
| DrawPrimitive | |
![]() | minZ : Number
Indicates the minimum z value of the drawing primitive.
| DrawPrimitive | |
![]() | projection : Projection
Reference to the last projection object used for the primitive
| DrawPrimitive | |
![]() | quadrant : PrimitiveQuadrantTreeNode
Reference to the last quadrant used by the drawing primitive.
| DrawPrimitive | |
![]() | screenZ : Number
Indicates the screen z value of the drawing primitive (used for z-sorting).
| DrawPrimitive | |
![]() | source : Object3D
The parent 3d object of the drawing primitive.
| DrawPrimitive | |
| texturemapping : Matrix
The texturemapping matrix of the triangle primitive texture.
| DrawTriangle | ||
| uv0 : UV
The uv0 uv coordinate of the triangle primitive.
| DrawTriangle | ||
| uv1 : UV
The uv1 uv coordinate of the triangle primitive.
| DrawTriangle | ||
| uv2 : UV
The uv2 uv coordinate of the triangle primitive.
| DrawTriangle | ||
| v0 : ScreenVertex
The v0 screenvertex of the triangle primitive.
| DrawTriangle | ||
| v1 : ScreenVertex
The v1 screenvertex of the triangle primitive.
| DrawTriangle | ||
| v2 : ScreenVertex
The v2 screenvertex of the triangle primitive.
| DrawTriangle | ||
| Method | Defined by | ||
|---|---|---|---|
|
calc():void
Calculates the min, max and screen properties required for rendering the drawing primitive.
| DrawTriangle | ||
|
clear():void
Deletes the data currently held by the drawing primitive.
| DrawTriangle | ||
|
Determines whether the given point lies inside the drawing primitive
| DrawTriangle | ||
|
distanceToCenter(x:Number, y:Number):Number
| DrawTriangle | ||
|
Calulates the uv value of a precise point on the drawing primitive.
| DrawTriangle | ||
|
Calulates the screen z value of a precise point on the drawing primitive.
| DrawTriangle | ||
|
Cuts the drawing primitive into 4 equally sized drawing primitives.
| DrawTriangle | ||
|
render():void
Draws the primitive to the view.
| DrawTriangle | ||
|
toString():String
Used to trace the values of a drawing primitive.
| DrawTriangle | ||
|
Calculates from the uv coordinates the mapping matrix required to draw the triangle primitive.
| DrawTriangle | ||
| area | property |
public var area:Number
The calulated area of the triangle primitive.
| backface | property |
public var backface:Boolean = false
Indicates whether the face of the triangle primitive is facing away from the camera.
| face | property |
| invtexturemapping | property |
public var invtexturemapping:Matrix
The inverse texturemapping matrix of the triangle primitive texture.
| material | property |
| texturemapping | property |
public var texturemapping:Matrix
The texturemapping matrix of the triangle primitive texture.
| uv0 | property |
| uv1 | property |
| uv2 | property |
| v0 | property |
| v1 | property |
| v2 | property |
| calc | () | method |
public override function calc():void
Calculates the min, max and screen properties required for rendering the drawing primitive.
| clear | () | method |
public override function clear():void
Deletes the data currently held by the drawing primitive.
| contains | () | method |
public final override function contains(x:Number, y:Number):Boolean
Determines whether the given point lies inside the drawing primitive
Parametersx:Number — The x position of the point to be tested.
|
|
y:Number — The y position of the point to be tested.
|
Boolean — The result of the test.
|
| distanceToCenter | () | method |
public final function distanceToCenter(x:Number, y:Number):Number
x:Number |
|
y:Number |
Number |
| getUV | () | method |
public function getUV(x:Number, y:Number):UV
Calulates the uv value of a precise point on the drawing primitive. Used to determine the mouse position in interactive materials.
Parametersx:Number — The x position of the point to be tested.
|
|
y:Number — The y position of the point to be tested.
|
UV —
The uv value.
|
| getZ | () | method |
public final override function getZ(x:Number, y:Number):Number
Calulates the screen z value of a precise point on the drawing primitive.
Parametersx:Number — The x position of the point to be tested.
|
|
y:Number — The y position of the point to be tested.
|
Number — The screen z value (used in z-sorting).
|
| quarter | () | method |
public final override function quarter(focus:Number):Array
Cuts the drawing primitive into 4 equally sized drawing primitives. Used in z-sorting correction.
Parametersfocus:Number — The focus value of the camera being used in the view.
|
Array |
| render | () | method |
public override function render():void
Draws the primitive to the view.
| toString | () | method |
public override function toString():String
Used to trace the values of a drawing primitive.
ReturnsString — A string representation of the drawing primitive.
|
| transformUV | () | method |
public final function transformUV(material:IUVMaterial):Matrix
Calculates from the uv coordinates the mapping matrix required to draw the triangle primitive.
Parametersmaterial:IUVMaterial |
Matrix |