Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

179
Vistas
How do I get Hue Rotate to only rotate the hue, and not affect saturation or luminosity?

I have successfully managed to implement a random hue selector into my random character code, but another problem presents itself with this acheivement. The random hue picker that I've made work in JavaScript doesn't affect the colour change that I want correctly. If you want to see the goal of what I want to achieve, you can see that here

I am unsure of why this strange application of hue rotation is occuring. The code that governs hue selection in my code is this:

    var robothue = new Image(); 
    var robothuenum=Math.floor(Math.random()*359)+1; //Randomiser selects a value between 1 and 360.

    canvas.style.filter = 'hue-rotate(' + robothuenum + 'deg)'; //This line applies the hue filter mentioned above.

Link to the full code here, with necessary image files to function correctly, if you want to try it out for yourself and figure out how to fix the hue rotation so it lines up more with the example image: https://github.com/Briochewindows/Random-Colour-Character-Generator.git

about 4 years ago · Santiago Gelvez
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda