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

267
Visualizações
How do I make a circular music visualizer in p5.js?

What I am getting looks like a red Spirograph

What I want white circle with waves in it

I am trying to create a music music visualization app and I am stuck on the circular wave pattern

//draw the waveform to the screen
function CircularWavePattern() {
    //vis name
    this.name = "circularWavePattern";

    //draw the wave form to the screen
    this.draw = function() {
        push();
        noFill();
        stroke(255, 0, 0);
        strokeWeight(2);

        
        beginShape();
        //calculate the waveform from the fft.
        var wave = fourier.waveform();
        
        for (var i = 0; i < wave.length; i++) {
            //for each element of the waveform map it to screen
            //coordinates and make a new vertex at the point.
            var x = map(i, 0, wave.length, 0, width) * cos(i);
            var y = map(wave[i], -1, 1, 0, height) * sin(i);

            vertex(x, y);
        }

        endShape();
        pop();
    };
}
about 4 years ago · Juan Pablo Isaza
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