Examples of interpolate()


Examples of crazypants.vecmath.Vector4f.interpolate()

    double ratio = dispDamage / maxDam;
    Vector4f fg = ColorUtil.toFloat(full);
    Vector4f ec = ColorUtil.toFloat(empty);
    fg.interpolate(ec, (float) ratio);
    Vector4f bg = ColorUtil.toFloat(Color.black);
    bg.interpolate(fg, 0.15f);
   
    int barLength = (int) Math.round(12.0 * (1 - ratio));   
   
    RenderUtil.renderQuad2D(2, y, 0, 12, 1, bg);
    RenderUtil.renderQuad2D(2, y, 0, barLength, 1, fg);
View Full Code Here

Examples of de.hunsicker.jalopy.storage.Environment.interpolate()

        String classMask = "/**\n * @author $author$\n*/";

        convention.put(
                ConventionKeys.COMMENT_JAVADOC_TEMPLATE_CLASS,
                env.interpolate(classMask));

        convention.put(
                ConventionKeys.COMMENT_JAVADOC_TEMPLATE_INTERFACE,
                env.interpolate(classMask));

View Full Code Here

Examples of flanagan.interpolation.BiCubicSpline.interpolate()

            refind=refind2+(refind3-refind2)*concw/(5.0);
          }
        }
        else{
          BiCubicSpline bcs = new BiCubicSpline(tempw, weight, corrfac);
          corrfactor = bcs.interpolate(temperature, concw);
          concw=concw+corrfactor;
          concg=Sucrose.weightpercentToGperl(concw, temperature);
          refind=CubicSpline.interpolate(concg, concnG, refInd, deriv);
        }
      }
View Full Code Here

Examples of flanagan.interpolation.CubicSpline.interpolate()

                interpData = new double[nInterp];
                CubicSpline cs = new CubicSpline(dataX, this.sortedData);
                double interp = 0.0;
                for(int i=0; i<nInterp-1; i++){
                    interpData[i]=cs.interpolate(interp);
                    interp += incrI;

                }
                interpData[nInterp-1] = (double)(this.numberOfDataPoints-1);
            }
View Full Code Here

Examples of flanagan.interpolation.LinearInterpolation.interpolate()

                double scale = yError/this.weightsMean;
                for(int i=0; i<this.nAnalyteConcns; i++)sWeights[i] = weights[i]*scale;
                if(this.weightsEntered && !monoCheck){
                    // linear interpolation if weights are non-monotonic or have big jumps
                    LinearInterpolation liee = new LinearInterpolation(this.analyteConcns, sWeights);
                    for(int i=0; i<this.nWorking; i++)ee[i] = Math.abs(liee.interpolate(xx[i]));
                }
                else{
                    // cubic spline interpolation if weights are monotonic without big jumps
                    CubicSpline csee = new CubicSpline(this.analyteConcns, sWeights);
                    for(int i=0; i<this.nWorking; i++)ee[i] = Math.abs(csee.interpolate(xx[i]));
View Full Code Here

Examples of javax.media.jai.Interpolation.interpolate()

                // Computes the expected value:
                double s00 = data.getSampleDouble(i+0, j+0, band);
                double s01 = data.getSampleDouble(i+0, j+1, band);
                double s10 = data.getSampleDouble(i+1, j+0, band);
                double s11 = data.getSampleDouble(i+1, j+1, band);
                double s = interpolation.interpolate(s00, s01, s10, s11, 0, 0);
                assertEquals(s, t, EPS);
            }
        }
    }
View Full Code Here

Examples of javax.validation.MessageInterpolator.interpolate()

    {
        String messageTemplate = (String) descriptor.getAttributes().get("message");

        MessageInterpolator messageInterpolator = validatorFactory.getMessageInterpolator();

        return messageInterpolator.interpolate(messageTemplate, new Context()
        {

            @Override
            public ConstraintDescriptor<?> getConstraintDescriptor()
            {
View Full Code Here

Examples of javax.vecmath.Color3f.interpolate()

        branchGroup.setCapability(BranchGroup.ALLOW_DETACH);
    }

    private void setColor(Percent efficiency) {
        Color3f leafColor = new Color3f(ColorConstants.brownYellow);
        leafColor.interpolate(ColorConstants.green, efficiency.getValue().floatValue());

        Appearance appearance = new Appearance();
        AppearanceFactory.setCullFace(appearance, PolygonAttributes.CULL_NONE);
        AppearanceFactory.setColorWithMaterial(appearance, leafColor, new Color3f(0.15f, 0.15f, 0.15f), new Color3f(
                0.05f, 0.05f, 0.05f));
View Full Code Here

Examples of javax.vecmath.Point2d.interpolate()

        double rad=BondTools.giveAngleBothMethods(new Point2d(wedge.firstPointX,wedge.firstPointY), new Point2d(wedge.firstPointX+100,wedge.firstPointY), new Point2d(wedge.secondPointX,wedge.secondPointY), true);
        int degrees=(int)(360*(rad/(2*Math.PI)));
        // draw by interpolating along the imaginary straight line
        for (int i = 0; i < numberOfCircles; i++) {
            Point2d p1 = new Point2d();
            p1.interpolate(vertexA, vertexB, d);
            Point2d p2 = new Point2d();
            p2.interpolate(vertexA, vertexB, d+1/numberOfCircles);
           
            int[] p1T = this.transformPoint(p1.x, p1.y);
            int[] p2T = this.transformPoint(p2.x, p2.y);
View Full Code Here

Examples of javax.vecmath.Point3d.interpolate()

    public static Point3d getBarycentre(Point3d startPoint, Point3d endPoint, double distance) {
        double maxDistance = startPoint.distance(endPoint);
        double distanceToUse = computeDistanceToUse(maxDistance, distance);
        double ratio = distanceToUse / maxDistance;
        Point3d result = new Point3d();
        result.interpolate(startPoint, endPoint, ratio);
        return result;
    }

    /**
     * Bounds the given distance between 0 and maxDistance
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.