RotatePanInput
class RotatePanInput extends PanInput
A module that passes the angle moved by touch to Axes and uses one axis of rotation.
Details
constructor
new RotatePanInput(element, options)
| PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION | 
|---|---|---|---|---|
| element | HTMLElement | String | jQuery | An element to use the eg.Axes.RotatePanInput module | ||
| options | PanInputOption | ✔️ | The option object of the eg.Axes.PanInput module | 
const input = new eg.Axes.RotatePanInput("#area");
var axes = new eg.Axes({
    // property name('angle') could be anything you want (eg. x, y, z...)
    angle: {
        range: [-180, 180] // from -180deg to 180deg
    }
});
axes.connect("angle", input)
Methods
destroy
Destroys elements, properties, and events used in a module.
enable
Enables input devices
Returns: PanInput
- An instance of a module itself
 
disable
Disables input devices
Returns: PanInput
- An instance of a module itself
 
isEnabled
Returns whether to use an input device
Returns: Boolean
- Whether to use an input device
 
release
Releases current user input.
Returns: PanInput
- An instance of a module itself