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

234
Vistas
How can I get the rotateY value from martix?

I got rotateY throw this method,but how can I get rotateY from 0 to 360?

var _getTransform = function($element) {

var matrix = $element.css('transform'),
    rotateX = 0,
    rotateY = 0,
    rotateZ = 0;

if (matrix !== 'none') {

    // do some magic
    var values = matrix.split('(')[1].split(')')[0].split(','),
        pi = Math.PI,
        sinB = parseFloat(values[8]),
        b = Math.round(Math.asin(sinB) * 180 / pi),
        cosB = Math.cos(b * pi / 180),
        matrixVal10 = parseFloat(values[9]),
        a = Math.round(Math.asin(-matrixVal10 / cosB) * 180 / pi),
        matrixVal1 = parseFloat(values[0]),
        c = Math.round(Math.acos(matrixVal1 / cosB) * 180 / pi);

    rotateX = a;
    rotateY = b;
    rotateZ = c;

}

return {
    rotateX: rotateX,
    rotateY: rotateY,
    rotateZ: rotateZ
};

}

css: transform: rotateY(110deg) rotateX(10deg);

I got: rotateX:28 rotateY:68 rotateZ:156

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