// Path: sdk/src/main/java/com/theeyetribe/clientsdk/data/Point2D.java
// public class Point2D
// {
//     public float x;
//     public float y;
// 
//     public static final float EPSILON = 1e-005f;
// 
//     public static final Point2D ZERO = new Point2D();
// 
//     public Point2D()
//     {
//     }
// 
//     public Point2D(float x, float y)
//     {
//         this.x = x;
//         this.y = y;
//     }
// 
//     public Point2D(Point2D point)
//     {
//         x = point.x;
//         y = point.y;
//     }
// 
//     @Override
//     public boolean equals(Object o)
//     {
//         if (this == o)
//             return true;
// 
//         if (!(o instanceof Point2D))
//             return false;
// 
//         Point2D other = (Point2D) o;
// 
//         return
//             Float.compare(this.x, other.x) == 0 &&
//             Float.compare(this.y, other.y) == 0 ;
//     }
// 
//     @Override
//     public int hashCode()
//     {
//         int hash = 571;
//         hash = hash * 2777 + HashUtils.hash(x);
//         hash = hash * 2777 + HashUtils.hash(y);
//         return hash;
//     }
// 
//     public Point2D add(Point2D p2)
//     {
//         return new Point2D(this.x + p2.x, this.y + p2.y);
//     }
// 
//     public Point2D subtract(Point2D p2)
//     {
//         return new Point2D(this.x - p2.x, this.y - p2.y);
//     }
// 
//     public Point2D multiply(Point2D p2)
//     {
//         return new Point2D(this.x * p2.x, this.y * p2.y);
//     }
// 
//     public Point2D multiply(float k)
//     {
//         return new Point2D(this.x * k, this.y * k);
//     }
// 
//     public Point2D divide(float k)
//     {
//         return new Point2D(this.x / k, this.y / k);
//     }
// 
//     public float average()
//     {
//         return (x + y) / 2;
//     }
// 
//     @Override
//     public String toString()
//     {
//         return "{" + x + ", " + y + "}";
//     }
// }


import com.theeyetribe.clientsdk.data.CalibrationResult;
import com.theeyetribe.clientsdk.data.Point2D;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
        {
            return 4;
        }
        else if (cq.equals(CalibQuality.GOOD))
        {
            return 3;
        }
        else if (cq.equals(CalibQuality.MODERATE))
        {
            return 2;
        }
        else if (cq.equals(CalibQuality.POOR))
        {
            return 1;
        }

        return 0;
    }

    /**
     * Helper method that generates geometric calibration points based on desired rect area.
     * <p>
     * This is useful when implementing a custom calibration UI.
     *
     * @param rows the number of rows in calibration point grid
     * @param columns the number of columns in calibration point grid
     * @param width width of the rect area to spread the calibration points in
     * @param height height of the rect area to spread the calibration points in
     * @return list of calibration points
     */
// Path: sdk/src/main/java/com/theeyetribe/clientsdk/data/Point2D.java
// public class Point2D
// {
//     public float x;
//     public float y;
// 
//     public static final float EPSILON = 1e-005f;
// 
//     public static final Point2D ZERO = new Point2D();
// 
//     public Point2D()
//     {
//     }
// 
//     public Point2D(float x, float y)
//     {
//         this.x = x;
//         this.y = y;
//     }
// 
//     public Point2D(Point2D point)
//     {
//         x = point.x;
//         y = point.y;
//     }
// 
//     @Override
//     public boolean equals(Object o)
//     {
//         if (this == o)
//             return true;
// 
//         if (!(o instanceof Point2D))
//             return false;
// 
//         Point2D other = (Point2D) o;
// 
//         return
//             Float.compare(this.x, other.x) == 0 &&
//             Float.compare(this.y, other.y) == 0 ;
//     }
// 
//     @Override
//     public int hashCode()
//     {
//         int hash = 571;
//         hash = hash * 2777 + HashUtils.hash(x);
//         hash = hash * 2777 + HashUtils.hash(y);
//         return hash;
//     }
// 
//     public Point2D add(Point2D p2)
//     {
//         return new Point2D(this.x + p2.x, this.y + p2.y);
//     }
// 
//     public Point2D subtract(Point2D p2)
//     {
//         return new Point2D(this.x - p2.x, this.y - p2.y);
//     }
// 
//     public Point2D multiply(Point2D p2)
//     {
//         return new Point2D(this.x * p2.x, this.y * p2.y);
//     }
// 
//     public Point2D multiply(float k)
//     {
//         return new Point2D(this.x * k, this.y * k);
//     }
// 
//     public Point2D divide(float k)
//     {
//         return new Point2D(this.x / k, this.y / k);
//     }
// 
//     public float average()
//     {
//         return (x + y) / 2;
//     }
// 
//     @Override
//     public String toString()
//     {
//         return "{" + x + ", " + y + "}";
//     }
// }


// Path: sdk/src/main/java/com/theeyetribe/clientsdk/utils/CalibUtils.java
import com.theeyetribe.clientsdk.data.CalibrationResult;
import com.theeyetribe.clientsdk.data.Point2D;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

        {
            return 4;
        }
        else if (cq.equals(CalibQuality.GOOD))
        {
            return 3;
        }
        else if (cq.equals(CalibQuality.MODERATE))
        {
            return 2;
        }
        else if (cq.equals(CalibQuality.POOR))
        {
            return 1;
        }

        return 0;
    }

    /**
     * Helper method that generates geometric calibration points based on desired rect area.
     * <p>
     * This is useful when implementing a custom calibration UI.
     *
     * @param rows the number of rows in calibration point grid
     * @param columns the number of columns in calibration point grid
     * @param width width of the rect area to spread the calibration points in
     * @param height height of the rect area to spread the calibration points in
     * @return list of calibration points
     */
    public static List<Point2D> initCalibrationPoints(int rows, int columns, int width, int height)