When adding the embedded component to a scene for easier styling of elements in my AR scene, the raycast/click event does not trigger on the correct spot. When I remove the embedded tag from the scene the raycast is working like it should but the objects in the scene are at different scales/positions when viewing the webpage on a mobile device.
Is there any way to have propper raycasting in an embedded scene?
<body style="margin: 0px; overflow: hidden">
<a-scene embedded arjs="debugUIEnabled: false; sourceType: webcam">
<a-marker type='pattern' url='custommarkers/pattern-marker.patt' cursor="rayOrigin: mouse; fuse: false">
<a-circle id="button" src="#buttonimg" radius=".2" rotation="-90 0 0" position="0 0 1">
<a-animation begin="buttonpressed" dur="750" attribute="scale" to="2 4 4" direction="alternate"></a-animation>
</a-circle>
</a-marker>
</a-scene>
</body>
The 'buttonpressed' is an event send from the button when it is clicked. I can click 'The button' but not on a spot where the graphic of the circle is
` element on the screen on click
– Piotr Adam Milewski Nov 12 '18 at 21:52