Packageaway3d.primitives
Classpublic class PrimitiveBase
InheritancePrimitiveBase Inheritance Geometry Inheritance NamedAssetBase Inheritance flash.events.EventDispatcher
Subclasses CapsuleGeometry, CubeGeometry, CylinderGeometry, NURBSGeometry, PlaneGeometry, SphereGeometry, TorusGeometry

PrimitiveBase is an abstract base class for mesh primitives, which are prebuilt simple meshes.



Public Properties
 PropertyDefined By
 InheritedassetFullPath : Array
[read-only]
NamedAssetBase
 InheritedassetNamespace : String
[read-only]
NamedAssetBase
 InheritedassetType : String
[read-only]
Geometry
 Inheritedname : String
NamedAssetBase
 InheritedoriginalName : String
[read-only] The original name used for this asset in the resource (e.g.
NamedAssetBase
  subGeometries : Vector.<ISubGeometry>
[override] [read-only] A collection of SubGeometry objects, each of which contain geometrical data such as vertices, normals, etc.
PrimitiveBase
Protected Properties
 PropertyDefined By
  _geomDirty : Boolean = true
PrimitiveBase
  _uvDirty : Boolean = true
PrimitiveBase
Public Methods
 MethodDefined By
  
Creates a new PrimitiveBase object.
PrimitiveBase
 Inherited
addSubGeometry(subGeometry:ISubGeometry):void
Adds a new SubGeometry object to the list.
Geometry
  
applyTransformation(transform:Matrix3D):void
[override]
PrimitiveBase
 Inherited
assetPathEquals(name:String, ns:String):Boolean
NamedAssetBase
  
[override] Clones the geometry.
PrimitiveBase
 Inherited
Updates the SubGeometries so all vertex data is represented in different buffers.
Geometry
 Inherited
dispose():void
Clears all resources used by the Geometry object, including SubGeometries.
Geometry
 Inherited
Removes a new SubGeometry object from the list.
Geometry
 Inherited
resetAssetPath(name:String, ns:String = null, overrideOriginal:Boolean = true):void
NamedAssetBase
  
scale(scale:Number):void
[override] Scales the geometry.
PrimitiveBase
  
scaleUV(scaleU:Number = 1, scaleV:Number = 1):void
[override] Scales the uv coordinates (tiling)
PrimitiveBase
Protected Methods
 MethodDefined By
  
Builds the primitive's geometry when invalid.
PrimitiveBase
  
Builds the primitive's uv coordinates when invalid.
PrimitiveBase
  
Invalidates the primitive's geometry, causing it to be updated when requested.
PrimitiveBase
  
Invalidates the primitive's uv coordinates, causing them to be updated when requested.
PrimitiveBase
Public Constants
 ConstantDefined By
 InheritedDEFAULT_NAMESPACE : String = default
[static]
NamedAssetBase
Property Detail
_geomDirtyproperty
protected var _geomDirty:Boolean = true

_uvDirtyproperty 
protected var _uvDirty:Boolean = true

subGeometriesproperty 
subGeometries:Vector.<ISubGeometry>  [read-only] [override]

A collection of SubGeometry objects, each of which contain geometrical data such as vertices, normals, etc.


Implementation
    public function get subGeometries():Vector.<ISubGeometry>
Constructor Detail
PrimitiveBase()Constructor
public function PrimitiveBase()

Creates a new PrimitiveBase object.

Method Detail
applyTransformation()method
override public function applyTransformation(transform:Matrix3D):void

Parameters

transform:Matrix3D

buildGeometry()method 
protected function buildGeometry(target:CompactSubGeometry):void

Builds the primitive's geometry when invalid. This method should not be called directly. The calling should be triggered by the invalidateGeometry method (and in turn by updateGeometry).

Parameters

target:CompactSubGeometry

buildUVs()method 
protected function buildUVs(target:CompactSubGeometry):void

Builds the primitive's uv coordinates when invalid. This method should not be called directly. The calling should be triggered by the invalidateUVs method (and in turn by updateUVs).

Parameters

target:CompactSubGeometry

clone()method 
override public function clone():Geometry

Clones the geometry.

Returns
Geometry — An exact duplicate of the current Geometry object.
invalidateGeometry()method 
protected function invalidateGeometry():void

Invalidates the primitive's geometry, causing it to be updated when requested.

invalidateUVs()method 
protected function invalidateUVs():void

Invalidates the primitive's uv coordinates, causing them to be updated when requested.

scale()method 
override public function scale(scale:Number):void

Scales the geometry.

Parameters

scale:Number — The amount by which to scale.

scaleUV()method 
override public function scaleUV(scaleU:Number = 1, scaleV:Number = 1):void

Scales the uv coordinates (tiling)

Parameters

scaleU:Number (default = 1) — The amount by which to scale on the u axis. Default is 1;
 
scaleV:Number (default = 1) — The amount by which to scale on the v axis. Default is 1;

validate()method 
override arcane function validate():void