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

227
Visualizações
Smooth curve distribution of strength values (0-1) based on dynamic index (for slider control)

I've been searching forever on this, but my search-foo seems weak.

I have an array of items that I want to calculate a curved distribution of strength (from 0 to 1) based on some index value. For example with items [ {}, {}, {}, {}, {} ] (they're all objects in an array, so in this case there's 5 of them), so if I say the index is 3.7 (a floating point, the precission can vary, and represents the peek of distribution), I want back a distribution of strengths in a bell curve on both sides for my items.

I want to create a slider control for 100% (all items), and a strength curve / values for each item based on where I slide it to. A bonus would be some left/right smoothing as I reach the min/max values of the index, with an option to smooth the beginning and end for some looping functionality. In the end it will be a slider that controls the transparency of a number of objects from where the slider is currently at, so as you slide back and forth there's a nice easing curve of transparencies applied to the objects / layers.

I realize that even better would be if the easing and shape of the curve also can be controlled (by a size distribution value? maybe a curve shape? [wave,triangle,etc.]) but I might be getting ahead of myself.

Surely I'm not unique in trying to figure this out, but I must be searching for all the wrong things. I'm not a math guy, but I've tried all sorts of gaussian or bezier and spline and smoothing distributions of items / points from an index, and all sorts of variants and distributions and normalisations. I feel stupid. Please help. (I've tagged it as JS as that's my target, but anything will do)

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