Search code examples
aframe

Invoking timeout in aframe application during runtime


I am a Masters student working on developing an A-frame based VR application for my project and synchronizing its performance for multiple users in heterogeneous network conditions. Does anyone have any idea how can I invoke an asset timeout during runtime for any user who has a slower network connection with a latency of say more than 30ms. So basically if the latency is above 30ms, I want the asset timeout to be invoked so that the VR rendering can start. Thanks


Solution

  • You can use the a-assets timeout attribute

    <a-assets src="model.gltf" timeout="30">
      ...
    </a-assets>
    

    Consider that 30ms is not much time when fetching assets over the network.