dist/claygl.es.js
function (matrix) {

        var attributes = this.attributes;
        var positions = attributes.position.value;
        var normals = attributes.normal.value;
        var tangents = attributes.tangent.value;

        matrix = matrix.array;
        // Normal Matrix
        var inverseTransposeMatrix = mat4.create();
        mat4.invert(inverseTransposeMatrix, matrix);
        mat4.transpose(inverseTransposeMatrix, inverseTransposeMatrix);

        var vec3TransformMat4 = vec3.transformMat4;
        var vec3ForEach = vec3.forEach;
        vec3ForEach(positions, 3, 0, null, vec3TransformMat4, matrix);
        if (normals) {
            vec3ForEach(normals, 3, 0, null, vec3TransformMat4, inverseTransposeMatrix);
        }
        if (tangents) {
            vec3ForEach(tangents, 4, 0, null, vec3TransformMat4, inverseTransposeMatrix);
        }

        if (this.boundingBox) {
            this.updateBoundingBox();
        }
    }
function (matrix) {

        var attributes = this.attributes;
        var positions = attributes.position.value;
        var normals = attributes.normal.value;
        var tangents = attributes.tangent.value;

        matrix = matrix.array;
        // Normal Matrix
        var inverseTransposeMatrix = mat4.create();
        mat4.invert(inverseTransposeMatrix, matrix);
        mat4.transpose(inverseTransposeMatrix, inverseTransposeMatrix);

        var vec3TransformMat4 = vec3.transformMat4;
        var vec3ForEach = vec3.forEach;
        vec3ForEach(positions, 3, 0, null, vec3TransformMat4, matrix);
        if (normals) {
            vec3ForEach(normals, 3, 0, null, vec3TransformMat4, inverseTransposeMatrix);
        }
        if (tangents) {
            vec3ForEach(tangents, 4, 0, null, vec3TransformMat4, inverseTransposeMatrix);
        }

        if (this.boundingBox) {
            this.updateBoundingBox();
        }
    }
function ( matrix ) { var attributes = this . attributes ; var positions = attributes . position . value ; var normals = attributes . normal . value ; var tangents = attributes . tangent . value ; matrix = matrix . array ; // Normal Matrix var inverseTransposeMatrix = mat4 . create ( ) ; mat4 . invert ( inverseTransposeMatrix , matrix ) ; mat4 . transpose ( inverseTransposeMatrix , inverseTransposeMatrix ) ; var vec3TransformMat4 = vec3 . transformMat4 ; var vec3ForEach = vec3 . forEach ; vec3ForEach ( positions , 3 , 0 , null , vec3TransformMat4 , matrix ) ; if ( normals ) { vec3ForEach ( normals , 3 , 0 , null , vec3TransformMat4 , inverseTransposeMatrix ) ; } if ( tangents ) { vec3ForEach ( tangents , 4 , 0 , null , vec3TransformMat4 , inverseTransposeMatrix ) ; } if ( this . boundingBox ) { this . updateBoundingBox ( ) ; } }
Apply transform to geometry attributes.
@param {clay.Matrix4} matrix
Apply transform to geometry attributes .