Class LeftEyePupil

java.lang.Object
adaptlil.data_classes.LeftEyePupil

public class LeftEyePupil extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private double
     
    private boolean
     
    private double
     
    private double
     
    private double
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    Empty default constructor for Jackson Serialization
    LeftEyePupil(double x, double y, double diameter, double scale, boolean isValid)
    Pupil data for the left eye
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    The diameter of the left eye pupil in pixels.
    getLeftEyePupilFromCsvLine(int lpcxIndex, int lpcyIndex, int lpsIndex, int lpdIndex, int lpvIndex, String[] cells)
    Reads LeftEyePupil data from the csv generated via gazepoint.
    double
    The scale factor of the left eye pupil (unitless).
    double
    The X-coordinate of the left eye pupil in the camera image, as a fraction of the camera image size
    double
    The Y-coordinate of the left eye pupil in the camera image, as a fraction of the camera image size
    interpolate(LeftEyePupil firstLeftEyePupil, LeftEyePupil nextLeftEyePupil, int nSteps)
    Performs Linear interpolation nSteps LeftEyePupil elements between the first LeftEyePupil and the next LeftEyePupil
    boolean
    The valid flag with value of 1 if the data is valid, and 0 if it is not.
    void
    setDiameter(double diameter)
    The diameter of the left eye pupil in pixels.
    void
    setIsValid(boolean isValid)
     
    void
    setScale(double scale)
    The scale factor of the left eye pupil (unitless).
    void
    setX(double x)
    X-Coordinate of left eye
    void
    setY(double y)
    Y-Coordinate of left eye

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • x

      private double x
    • y

      private double y
    • diameter

      private double diameter
    • scale

      private double scale
    • isValid

      private boolean isValid
  • Constructor Details

    • LeftEyePupil

      public LeftEyePupil()
      Empty default constructor for Jackson Serialization
    • LeftEyePupil

      public LeftEyePupil(double x, double y, double diameter, double scale, boolean isValid)
      Pupil data for the left eye
      Parameters:
      x - fraction of camera image size
      y - fraction of camera image size
      diameter - in pixels
      scale - depth of how far a user's eye is from the tracker
      isValid - flag to determine if this object data is valid (determiend by tracker)
  • Method Details

    • getLeftEyePupilFromCsvLine

      public static LeftEyePupil getLeftEyePupilFromCsvLine(int lpcxIndex, int lpcyIndex, int lpsIndex, int lpdIndex, int lpvIndex, String[] cells)
      Reads LeftEyePupil data from the csv generated via gazepoint.
      Parameters:
      lpcxIndex -
      lpcyIndex -
      lpsIndex -
      lpdIndex -
      lpvIndex -
      cells -
      Returns:
    • interpolate

      public LeftEyePupil[] interpolate(LeftEyePupil firstLeftEyePupil, LeftEyePupil nextLeftEyePupil, int nSteps)
      Performs Linear interpolation nSteps LeftEyePupil elements between the first LeftEyePupil and the next LeftEyePupil
      Parameters:
      firstLeftEyePupil -
      nextLeftEyePupil -
      nSteps -
      Returns:
    • setX

      public void setX(double x)
      X-Coordinate of left eye
      Parameters:
      x - fraction of camera image size
    • setY

      public void setY(double y)
      Y-Coordinate of left eye
      Parameters:
      y - fraction of camera image size
    • setDiameter

      public void setDiameter(double diameter)
      The diameter of the left eye pupil in pixels.
      Parameters:
      diameter - in pixels
    • setScale

      public void setScale(double scale)
      The scale factor of the left eye pupil (unitless). Value equals 1 at calibration depth, is less than 1 when user is closer to the eye tracker and greater than 1 when user is further away.
      Parameters:
      scale - [1,inf]
    • setIsValid

      public void setIsValid(boolean isValid)
      Parameters:
      isValid -
    • getX

      public double getX()
      The X-coordinate of the left eye pupil in the camera image, as a fraction of the camera image size
      Returns:
      double
    • getY

      public double getY()
      The Y-coordinate of the left eye pupil in the camera image, as a fraction of the camera image size
      Returns:
      double
    • getDiameter

      public double getDiameter()
      The diameter of the left eye pupil in pixels.
      Returns:
      double
    • getScale

      public double getScale()
      The scale factor of the left eye pupil (unitless). Value equals 1 at calibration depth, is less than 1 when user is closer to the eye tracker and greater than 1 when user is further away
      Returns:
      double
    • isValid

      public boolean isValid()
      The valid flag with value of 1 if the data is valid, and 0 if it is not.
      Returns: