Packagecom.gestureworks.analysis
Classpublic class VectorMetric
InheritanceVectorMetric Inheritance Object



Public Properties
 PropertyDefined By
  HalfDiagonal : Number
[static]
VectorMetric
  height : Number = 0
[static]
VectorMetric
  NumPoints : int = 30
[static]
VectorMetric
  pointList : Vector.<PointObject>
VectorMetric
  SquareSize : Number = 250.0
[static]
VectorMetric
  width : Number = 0
[static]
VectorMetric
Public Methods
 MethodDefined By
  
VectorMetric(_id:int)
VectorMetric
  
BoundingBox(points:Array):Rectangle
[static]
VectorMetric
  
Centroid(points:Array):Point
[static]
VectorMetric
  
CompareRawToNormalizedPathCollection(path:Array, pathCollection:Vector.<Array>):Object
[static]
VectorMetric
  
Distance(p1:Object, p2:Object):Number
[static]
VectorMetric
  
VectorMetric
  
VectorMetric
  
VectorMetric
  
VectorMetric
  
VectorMetric
  
init():void
VectorMetric
  
normalize(collection:Array):Array
[static]
VectorMetric
  
VectorMetric
  
PathDistance(pts1:Array, pts2:Array):Number
[static]
VectorMetric
  
PathLength(points:Array):Number
[static]
VectorMetric
  
Resample(points:Array, n:int):Array
[static]
VectorMetric
  
VectorMetric
  
ScaleToSquare(points:Array, size:Number):Array
[static]
VectorMetric
  
TranslateToOrigin(points:Array):Array
[static]
VectorMetric
Property Detail
HalfDiagonalproperty
public static var HalfDiagonal:Number

heightproperty 
public static var height:Number = 0

NumPointsproperty 
public static var NumPoints:int = 30

pointListproperty 
public var pointList:Vector.<PointObject>

SquareSizeproperty 
public static var SquareSize:Number = 250.0

widthproperty 
public static var width:Number = 0

Constructor Detail
VectorMetric()Constructor
public function VectorMetric(_id:int)



Parameters
_id:int
Method Detail
BoundingBox()method
public static function BoundingBox(points:Array):Rectangle

Parameters

points:Array

Returns
Rectangle
Centroid()method 
public static function Centroid(points:Array):Point

Parameters

points:Array

Returns
Point
CompareRawToNormalizedPathCollection()method 
public static function CompareRawToNormalizedPathCollection(path:Array, pathCollection:Vector.<Array>):Object

Parameters

path:Array
 
pathCollection:Vector.<Array>

Returns
Object
Distance()method 
public static function Distance(p1:Object, p2:Object):Number

Parameters

p1:Object
 
p2:Object

Returns
Number
findPathProperties()method 
public function findPathProperties():void

findStrokeGesture()method 
public function findStrokeGesture():void

getPathCollection()method 
public function getPathCollection():void

getSamplePath()method 
public function getSamplePath():void

getSamplePathPosition()method 
public function getSamplePathPosition():void

init()method 
public function init():void

normalize()method 
public static function normalize(collection:Array):Array

Parameters

collection:Array

Returns
Array
normalizeSamplePath()method 
public function normalizeSamplePath():void

PathDistance()method 
public static function PathDistance(pts1:Array, pts2:Array):Number

Parameters

pts1:Array
 
pts2:Array

Returns
Number
PathLength()method 
public static function PathLength(points:Array):Number

Parameters

points:Array

Returns
Number
Resample()method 
public static function Resample(points:Array, n:int):Array

Parameters

points:Array
 
n:int

Returns
Array
resetPathProperties()method 
public function resetPathProperties():void

ScaleToSquare()method 
public static function ScaleToSquare(points:Array, size:Number):Array

Parameters

points:Array
 
size:Number

Returns
Array
TranslateToOrigin()method 
public static function TranslateToOrigin(points:Array):Array

Parameters

points:Array

Returns
Array