Browse Source

Include handedness on the hands events

Fernando Serrano 5 years ago
parent
commit
85117979f8
1 changed files with 2 additions and 0 deletions
  1. 2 0
      src/renderers/webxr/WebXRController.js

+ 2 - 0
src/renderers/webxr/WebXRController.js

@@ -174,6 +174,7 @@ Object.assign( WebXRController.prototype, {
 							hand.inputState.pinching = false;
 							hand.inputState.pinching = false;
 							this.dispatchEvent( {
 							this.dispatchEvent( {
 								type: "pinchend",
 								type: "pinchend",
+								handedness: inputSource.handedness,
 								target: this
 								target: this
 							} );
 							} );
 
 
@@ -182,6 +183,7 @@ Object.assign( WebXRController.prototype, {
 							hand.inputState.pinching = true;
 							hand.inputState.pinching = true;
 							this.dispatchEvent( {
 							this.dispatchEvent( {
 								type: "pinchstart",
 								type: "pinchstart",
+								handedness: inputSource.handedness,
 								target: this
 								target: this
 							} );
 							} );