ReactVision/viro

Viro3DObject: sometime does not respond to pinch and drag gesture

Opened this issue · 2 comments

Hello Everyone

  1. Development OS: Mac
  2. iOS version (16.1) & Android Version : 9.0
  3. ViroReact version : 2.23.0 and React Native version : 0.66.2
  4. Device(s):iPhone 12 Pro, OPPO A31

Description

I have created an AR scene with ViroReact on both android and iOS. At starting everything works perfectly on scene but after using is for something all added 3D object on screen just stop responding to pinch and drag but rotation of object can be done.

<Viro3DObject source={modelItem.arUrl} type={modelItem.arType} materials={modelItem.arTexture ? modelItem.arTexture : 'pbr'} resources={modelItem.arResources} animation={{ ...modelItem.arAnimation, run: this.state.runAnimation, }} lightReceivingBitMask={this.props.bitMask | 1} shadowCastingBitMask={this.props.bitMask} onClickState={this._onClickState(this.props.modelIDProps.uuid)} onClick={() => { if (modelItem.item) { this.props.mediaStore.sound = null; this.props.mediaStore.media = modelItem.item; this.props.mediaStore.modalVideo = true; } }} onError={this._onError(this.props.modelIDProps.uuid)} onRotate={this._onRotate} onPinch={(pinchState, scaleFactor, source) => { console.log('---------', modelItem.arType); this._onPinch(pinchState, scaleFactor, source); }} onLoadStart={this._onObjectLoadStart(this.props.modelIDProps.uuid)} onLoadEnd={this._onObjectLoadEnd(this.props.modelIDProps.uuid)} />

Any help greatly appreciated.

@sbgiri downgrade viro to 2.22.0 and issues with gesture events should gone or at least should improve in a way...

I am also facing same issue.

I tried to get it fixed by using GestureHandlerRootView of react-native-gesture-handler but got error of attempted to add a non component child of type

so what's solution for this Viro3DObject: sometime does not respond to pinch and drag gesture isuue.