Show:
Extends Inputs._TwoFingerInput

Detects two-finger rotational motion and emits start, update and end events with the payload data:

 count         - Number of simultaneous touches
 value         - Angle of rotation
 delta         - Differential of successive angles
 cumulate      - Total accumulated rotation
 velocity      - Velocity of rotation
 center        - Midpoint between the two touches

Constructor

Inputs.RotateInput

(
  • options
)

Parameters:

  • options Object

    Options

    • [scale=1] Number optional

      Scale the response to pinch

Example:

 var rotateInput = new RotateInput();
         rotateInput.subscribe(surface)
        
         rotateInput.on('start', function(payload){
             console.log('start', payload);
         });
        
         rotateInput.on('update', function(payload){
             console.log('update', payload);
         });
        
         rotateInput.on('end', function(payload){
             console.log('end', payload);
         });

Item Index