Skip to content

EyeTribe/tet-java-client

Repository files navigation

The Eye Tribe

Java SDK for the EyeTribe Dev Kit

This is the Java library implementation for the EyeTribe Dev Kit. This reference implementation provides a Java interface for communicating with the EyeTribe Server through the open EyeTribe API. The library allow developers to get started quickly and focus their efforts on creating truly immersive and innovative apps using our eye tracking technology.

Download

Download the latest JAR or via one of the following package services.

Gradle

Make sure your project is set up to use Bintray by adding the following to the project level build.gradle file.

apply plugin: 'java'
buildscript {
	repositories {
    	jcenter()
	}
}

Then grab the EyeTribe Java SDK package from any module.

compile 'com.theeyetribe:eyetribe-java:0.9.77'

Maven

Make sure your project is configured to use Bintray repository:

<repositories>
    <repository>
        <snapshots>
            <enabled>false</enabled>
        </snapshots>
        <id>bintray</id>
        <name>bintray</name>
        <url>http://jcenter.bintray.com</url>
    </repository>
</repositories>

Then add the EyeTribe Java SDK dependency

<dependency>
  <groupId>com.theeyetribe</groupId>
  <artifactId>eyetribe-java</artifactId>
  <version>0.9.77</version>
</dependency>

Documentation

Find documentation of this library at EyeTribe Java SDK Doc. The EyeTribe API reference is found at our Developer Website.

Samples

An essential part of using the EyeTribe Dev Kit is 'calibrating the system'. Doing so involves creating a UI that supports this library and guides the user through a series of mandatory steps.

Steps of the JavaFX calibration samples

This library holds a sample implementation of a Calibration UI using JavaFX. Find this under /javafx-sample. This sample runs on all platforms supported by the EyeTribe Dev Kit that have Java 8 installed.

Building (optional)

You can use the prebuilt version of this library though Gradle or Maven. See the JavaFX sample of this repo for an example of doing so. Should you wish to build it yourself follow the below instructions

Prerequisites:

  • Download & install Java JDK 6. Set environment variable 'JAVA6_HOME' to '${your.jdk6.path}'.
  • Download & install Java JDK 8. Set environment variable 'JAVA_HOME' and 'JAVA8_HOME' to '${your.jdk8.path}'.
  • Download & install InjelliJ IDEA or Gradle.

To build:

  • Import Gradle project to InjelliJ IDEA.
  • Set project language level to 8 in 'Module Setting -> Project'
  • Run gradle task 'sdk:jar'
  • Alternatively run task 'sdk:jar' using Gradle from the commandline.

Proguard

If you choose to build yourself and are using Proguard for obfuscation, be sure to add the following options.

-keepattributes Signature, *Annotation*
-keep class sun.misc.Unsafe { *; }
-keep class com.theeyetribe.client.response.* { *; }
-keep class com.theeyetribe.client.request.* { *; }
-keep class com.theeyetribe.client.data.* { *; }
-dontwarn java.lang.invoke.*
-dontwarn com.google.**

Getting Help

  • Have questions or need support? Visit our developer forum, to find answers to your questions and share your experiences with others developers.
  • Have a bug to report? Open a new issue and tell us what you are experiencing. Please add library version and full log if possible.
  • Have a feature request? Either open a new issue or post in our developer forum. Tell us what feature you are missing and what it should do.

Feedback

If you like using this library, please consider sending out a tweet mentioning @TheEyeTribe, announce your app in our developer forum, or email [email protected] to let us know.