Examples of negate()


Examples of aspect.util.Vector3.negate()

            float denom2 = Vector3.dot(normal, cross);
            float denom = denom1 + denom2;
            float impulse = num / denom;
            Vector3 impulseN = normal.times(impulse);
            impel(impulseN, pos1);
            rb2.impel(impulseN.negate(), pos2);

            // Frictional impulse
            Vector3 tangent = Vector3.cross(Vector3.cross(vr, normal), normal).normalize();
            if (tangent.mag2() == 0.0f) {
                return;
View Full Code Here

Examples of cc.redberry.core.number.Complex.negate()

                } else
                    indexlessArray.add(t);
            }

            if (powersContainer.isSign())
                factor = factor.negate();

            indexless = indexlessArray.toArray(new Tensor[indexlessArray.size()]);
            Arrays.sort(indexless);
        }
View Full Code Here

Examples of client.net.sf.saxon.ce.value.NumericValue.negate()

        NumericValue v1 = (NumericValue) operand.evaluateItem(context);
        if (v1 == null) {
            return backwardsCompatible ? DoubleValue.NaN : null;
        }
        return v1.negate();
    }


}
View Full Code Here

Examples of com.alibaba.security.simpleimage.analyze.sift.matrix.SimpleMatrix.negate()

        d.values[0][0] = 0.5 * (above.valArr[y][x] - below.valArr[y][x]);
        d.values[1][0] = 0.5 * (current.valArr[y + 1][x] - current.valArr[y - 1][x]);
        d.values[2][0] = 0.5 * (current.valArr[y][x + 1] - current.valArr[y][x - 1]);

        SimpleMatrix b = (SimpleMatrix) d.clone();
        b.negate();
        // Solve: A x = b
        H.solveLinear(b);
        ref.val = b.dot(d);
        return (b);
    }
View Full Code Here

Examples of com.github.sommeri.less4j.core.ast.NumberExpression.negate()

    if (value instanceof NumberExpression) {
      NumberExpression number = (NumberExpression) value;
      number.setExpliciteSign(true);

      if (sign.getType() == LessLexer.MINUS) {
        number.negate();
        number.setOriginalString("-" + number.getOriginalString());
      } else if (sign.getType() == LessLexer.PLUS) {
        number.setOriginalString("+" + number.getOriginalString());
      }
View Full Code Here

Examples of com.google.javascript.jscomp.newtypes.JSType.negate()

      JSType stopAfterLhsType = exprKind == Token.AND ?
          JSType.FALSY : JSType.TRUTHY;
      EnvTypePair shortCircuitPair =
          analyzeExprFwd(lhs, inEnv, requiredType, stopAfterLhsType);
      EnvTypePair lhsPair = analyzeExprFwd(
          lhs, inEnv, JSType.UNKNOWN, stopAfterLhsType.negate());
      EnvTypePair rhsPair =
          analyzeExprFwd(rhs, lhsPair.env, requiredType, specializedType);
      return EnvTypePair.join(rhsPair, shortCircuitPair);
    }
  }
View Full Code Here

Examples of com.jme.math.Vector3f.negate()

        Quaternion rotation = cell.getWorldTransform().getRotation(null);
        Vector3f lookVec = CellPlacementUtils.getLookDirection(rotation, null);

        // translate into a quaternion using lookAt
        Quaternion look = new Quaternion();
        look.lookAt(lookVec.negate(), Vector3f.UNIT_Y);

        // find the origin by translating the look vector
        Vector3f origin = lookVec.mult(distance);
        origin.addLocal(cell.getWorldTransform().getTranslation(null));
        return new CellTransform(look, origin);
View Full Code Here

Examples of com.jme.math.Vector3f.negate()

    public static Matrix4f computeViewPlatformTransform(Vector3f userPosition, Vector3f direction, Vector3f up) {       
        Matrix4f mat = new Matrix4f();
        Vector3f axisX = new Vector3f();
        Vector3f axisY = new Vector3f();
        Vector3f axisZ = new Vector3f(direction);
        axisZ.negate();
        axisZ.normalize();

        axisX.cross(up, axisZ);
        axisX.normalize();
View Full Code Here

Examples of com.jme.math.Vector3f.negate()

     */
    public static Quaternion getCellRotation(CellTransform viewTransform) {
        Quaternion viewRotation = viewTransform.getRotation(null);
        Vector3f lookAt = CellPlacementUtils.getLookDirection(viewRotation, null);
        Quaternion rotation = new Quaternion();
        rotation.lookAt(lookAt.negate(), new Vector3f(0, 1, 0));
        return rotation;
    }

    /**
     * Returns the distance away to play a Cell so that its horizontal bounds
View Full Code Here

Examples of com.jme3.math.Vector3f.negate()

        if (left) {
            walkDirection.addLocal(camLeft);
        }
        if (right) {
            walkDirection.addLocal(camLeft.negate());
        }
        if (up) {
            walkDirection.addLocal(camDir);
        }
        if (down) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.