new TrackPointer(options)
Tracker Class for linking an object's x and y to the pointer position.
Recommended for objects to be fixed: true to prevent any parent positioning from affecting the pointer tracking.
Parameters:
| Name | Type | Description |
|---|---|---|
options |
object | Object containing properties to be applied to the new instance. Reference the properties below. |
- Mixes In:
- Source:
Example
var scene = canvallax.Scene(),
arrow = canvallax.Polygon({
fill: '#000',
points: 3,
width: 100,
height: 100,
fixed: true
}),
tracker = canvallax.TrackPointer({ ease: 4 });
arrow.addTo(scene,tracker);