Examples of NdVector


Examples of engine.base.datastructure.NdVector

    return r * r + g * g + b * b;
  }
 
 
  final int findBestMatch_KDTree(int x, int y) {
    NdVector p = new NdVector(kdtree.getDimension());

    int num = 0;
    for (int sj = -border; sj <= 0; sj++) {
      for (int si = -border; si <= border; si++) {
        if ((sj == 0) && (si == 0))
          break;
        int tcolor = sampleTarget(x + si, y + sj);
        Vector4 color = Utils.RGBAToVector4(tcolor);
        p.set(num++, color.x);
        p.set(num++, color.y);
        p.set(num++, color.z);
      }
    }

    FeaturePoint fp = kdtree.getNearest(p);
    return fp.color;
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.