If this is possible, can I change the size of the aframe canvas in code?
I would like to display a form so that users can modify object parameters in the aframe scene.
Advertisement
Answer
See this question. How to remove fullscreen styles in A-Frame, reduce canvas size, or scroll a page with A-Frame scene?
You can use the embedded
component to remove fullscreen styles and make it embeddable within a web page. https://aframe.io/docs/1.1.0/components/embedded.html
JavaScript
x
4
1
<a-scene embedded>
2
<!-- scene stuff -->
3
</a-scene>
4
Then you are free the style <a-scene>
how you wish
JavaScript
1
2
1
a-scene { display: block; width: 50%; }
2