Java 类com.google.zxing.common.GridSampler 实例源码

项目:weex-3d-map    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:PortraitZXing    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:PortraitZXing    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:ZXing-Orient    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:event-app    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:weex-analyzer-android    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:weex-3d-map    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:Weex-TestDemo    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:QrScan_Demo    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:weex    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:TrueTone    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

    GridSampler sampler = GridSampler.getInstance();
    int dimension = getDimension();

    float low = dimension / 2.0f - nbCenterLayers;
    float high = dimension / 2.0f + nbCenterLayers;

    return sampler.sampleGrid(image,
            dimension,
            dimension,
            low, low,   // topleft
            high, low,  // topright
            high, high, // bottomright
            low, high,  // bottomleft
            topLeft.getX(), topLeft.getY(),
            topRight.getX(), topRight.getY(),
            bottomRight.getX(), bottomRight.getY(),
            bottomLeft.getX(), bottomLeft.getY());
}
项目:bushido-android-app    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:Android-Birdcopy-Application    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:zxing-bsplus    文件:Detector.java   
/**
 * Creates a BitMatrix by sampling the provided image.
 * topLeft, topRight, bottomRight, and bottomLeft are the centers of the squares on the
 * diagonal just outside the bull's eye.
 */
private BitMatrix sampleGrid(BitMatrix image,
                             ResultPoint topLeft,
                             ResultPoint topRight,
                             ResultPoint bottomRight,
                             ResultPoint bottomLeft) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  int dimension = getDimension();

  float low = dimension / 2.0f - nbCenterLayers;
  float high = dimension / 2.0f + nbCenterLayers;

  return sampler.sampleGrid(image,
                            dimension,
                            dimension,
                            low, low,   // topleft
                            high, low,  // topright
                            high, high, // bottomright
                            low, high,  // bottomleft
                            topLeft.getX(), topLeft.getY(),
                            topRight.getX(), topRight.getY(),
                            bottomRight.getX(), bottomRight.getY(),
                            bottomLeft.getX(), bottomLeft.getY());
}
项目:weex-3d-map    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:weex-3d-map    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:QrCode    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:boohee_v5.6    文件:Detector.java   
private BitMatrix sampleGrid(BitMatrix image, ResultPoint topLeft, ResultPoint topRight,
                             ResultPoint bottomRight, ResultPoint bottomLeft) throws
        NotFoundException {
    GridSampler sampler = GridSampler.getInstance();
    int dimension = getDimension();
    float low = (((float) dimension) / 2.0f) - ((float) this.nbCenterLayers);
    float high = (((float) dimension) / 2.0f) + ((float) this.nbCenterLayers);
    return sampler.sampleGrid(image, dimension, dimension, low, low, high, low, high, high,
            low, high, topLeft.getX(), topLeft.getY(), topRight.getX(), topRight.getY(),
            bottomRight.getX(), bottomRight.getY(), bottomLeft.getX(), bottomLeft.getY());
}
项目:boohee_v5.6    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image, ResultPoint topLeft, ResultPoint
        bottomLeft, ResultPoint bottomRight, ResultPoint topRight, int dimensionX, int
        dimensionY) throws NotFoundException {
    return GridSampler.getInstance().sampleGrid(image, dimensionX, dimensionY, 0.5f, 0.5f, (
            (float) dimensionX) - 0.5f, 0.5f, ((float) dimensionX) - 0.5f, ((float)
            dimensionY) - 0.5f, 0.5f, ((float) dimensionY) - 0.5f, topLeft.getX(), topLeft
            .getY(), topRight.getX(), topRight.getY(), bottomRight.getX(), bottomRight.getY()
            , bottomLeft.getX(), bottomLeft.getY());
}
项目:Tesseract-OCR-Scanner    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:QrCodeScanner    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:PortraitZXing    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:PortraitZXing    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:PortraitZXing    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:PortraitZXing    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:ZXing-Orient    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:ZXing-Orient    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:event-app    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:event-app    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:weex-analyzer-android    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:weex-analyzer-android    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:weex-3d-map    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:weex-3d-map    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:Weex-TestDemo    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:Weex-TestDemo    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:QrScan_Demo    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:QrScan_Demo    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:weex    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    PerspectiveTransform transform,
                                    int dimension) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();
  return sampler.sampleGrid(image, dimension, dimension, transform);
}
项目:weex    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix image,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint bottomRight,
                                    ResultPoint topRight,
                                    int dimensionX,
                                    int dimensionY) throws NotFoundException {

  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(image,
                            dimensionX,
                            dimensionY,
                            0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            0.5f,
                            dimensionX - 0.5f,
                            dimensionY - 0.5f,
                            0.5f,
                            dimensionY - 0.5f,
                            topLeft.getX(),
                            topLeft.getY(),
                            topRight.getX(),
                            topRight.getY(),
                            bottomRight.getX(),
                            bottomRight.getY(),
                            bottomLeft.getX(),
                            bottomLeft.getY());
}
项目:sres-app    文件:Detector.java   
private static BitMatrix sampleGrid(BitMatrix matrix,
                                    ResultPoint topLeft,
                                    ResultPoint bottomLeft,
                                    ResultPoint topRight,
                                    ResultPoint bottomRight,
                                    int xdimension,
                                    int ydimension) throws NotFoundException {

  // Note that unlike the QR Code sampler, we didn't find the center of modules, but the
  // very corners. So there is no 0.5f here; 0.0f is right.
  GridSampler sampler = GridSampler.getInstance();

  return sampler.sampleGrid(
      matrix, 
      xdimension, ydimension,
      0.0f, // p1ToX
      0.0f, // p1ToY
      xdimension, // p2ToX
      0.0f, // p2ToY
      xdimension, // p3ToX
      ydimension, // p3ToY
      0.0f, // p4ToX
      ydimension, // p4ToY
      topLeft.getX(), // p1FromX
      topLeft.getY(), // p1FromY
      topRight.getX(), // p2FromX
      topRight.getY(), // p2FromY
      bottomRight.getX(), // p3FromX
      bottomRight.getY(), // p3FromY
      bottomLeft.getX(), // p4FromX
      bottomLeft.getY()); // p4FromY
}