ISSUE:
In iOS Landscape mode, the Object is not placed in exact tap position in ViroARPlaneSelector.
The World-space position for tap given on onPlaneSelected callback itself is wrong for the same anchor id and tap position in portrait and landscape mode.
Tested on android portrait and landscape mode, the object is placed properly in tap position
Tested on iphone and ipad portrait mode, the object is placed properly in tap position
On iphone and ipad landscape mode, the object is NOT placed in correct tap position, it is placed randomly, sometimes even outside the anchor boundary
Sample Code
const onAnchorFound = useCallback((anchor: ViroAnchor) => {
ARPlaneSelectorRef.current?.handleAnchorFound(anchor)
}, []);
const onAnchorRemove = useCallback((anchor: ViroAnchor | undefined) => {
!!anchor && ARPlaneSelectorRef.current?.handleAnchorRemoved(anchor)
}, []);
const onAnchorUpdated = useCallback((anchor: ViroAnchor) => {
ARPlaneSelectorRef.current?.handleAnchorUpdated(anchor)
}, [])
<ViroARScene
anchorDetectionTypes={["PlanesHorizontal"]}
onAnchorFound={onAnchorFound}
onAnchorUpdated={onAnchorUpdated}
onAnchorRemoved={onAnchorRemove}
onCameraTransformUpdate={onCameraTransform}
>
<ViroARPlaneSelector ref={ARPlaneSelectorRef} onPlaneSelected={onPlaneSelect} onPlaneRemoved={onPlaneRemove}>
<ObjectNode ref={objectRef} />
</ViroARPlaneSelector>
</ViroARScene>
Package Versions
"@reactvision/react-viro": "2.57.3",
"react-native": "0.83.6",
iOS Version - 26.6
ISSUE:
In iOS Landscape mode, the Object is not placed in exact tap position in ViroARPlaneSelector.
The World-space position for tap given on onPlaneSelected callback itself is wrong for the same anchor id and tap position in portrait and landscape mode.
Tested on android portrait and landscape mode, the object is placed properly in tap position
Tested on iphone and ipad portrait mode, the object is placed properly in tap position
On iphone and ipad landscape mode, the object is NOT placed in correct tap position, it is placed randomly, sometimes even outside the anchor boundary
Sample Code
Package Versions
"@reactvision/react-viro": "2.57.3",
"react-native": "0.83.6",
iOS Version - 26.6