Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

199
Visualizações
Networked A-frame examples toggle video not working

I have created a remix of the Networked A-frame examples project. I've been testing out some features and for some reason, the toggle video button in the bottom left corner of the screen isn't working on the video example.

The function is triggering however it isn't changing the video from on to off and vice versa. I'm not sure why this is, but I'm wondering how I can make it so when the button is clicked, if video is on, it will turn off and if video is off, it will turn on. How can this be done? The code is found in public/examples/index.html at line 106 of this project:

https://glitch.com/edit/#!/modern-talented-tanker?path=examples%2Findex.html%3A116%3A0

Code snippet that isn't working:

// Handle camera button click (Off and On)
        cameraBtnEle.addEventListener('click', function() {
          NAF.connection.adapter.enableCamera(!cameraEnabled);
          cameraEnabled = !cameraEnabled;
          cameraBtnEle.textContent = cameraEnabled ? 'Hide Camera' : 'Show Camera';
        });
      }
about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

I've looked into the file You linked to, the code snippet found there doesn't match with the one you posted here, it references to the mic element in the linked file. What can i suggest is that you look into the example file called basic-video.html. You can find there the correct setup for video sharing in VR space. Remember to test it on 2 tabs / windows as if there is only one "player" the video sharing won't work.

For a detailed guide about video sharing in networked-aframe visit this link: https://github.com/networked-aframe/networked-aframe#video

This is the example with video sharing:
https://modern-talented-tanker.glitch.me/basic-video.html

Source code:
https://glitch.com/edit/#!/modern-talented-tanker?path=examples%2Fbasic-video.html

Good luck!

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda