Home › Forums › Software Development › [Solved] Turn On/Off Tobii device from code Unity
Tagged: disable eye tracker
- This topic has 10 replies, 5 voices, and was last updated 7 years, 6 months ago by Grant [Tobii].
- AuthorPosts
- 04/06/2015 at 13:14 #3067Vardan MeliksetyanParticipant
Hi tobii community.
I have question about mouse right click-> Disable Eye Tracking.
I want to write code in Unity, where user or in Awake() function I can turn on device lights. I can’t find info about it in docs. Can you help with info or link.
Thank you.09/06/2015 at 14:02 #3095Jenny [Tobii]ParticipantHi Vardan,
There is no API call to enable eye tracking when a user has disabled it. You have to let the users decide themselves if they want to enable eye tracking when running your game. You can check if eye tracking is disabled and advice the user to enable the eye tracker to be able to use your game/or the gaze-enabled features of your game. In the EyeXFramework included in the EyeX SDK for Unity there is a property called EyeTrackingDeviceStatus on the EyeXHost, and this will have the value “Disabled” when eye tracking is disabled. When eye tracking is ready for use the value is “Tracking” (meaning that the user’s eye-gaze is being tracked).
Note also that it is not only when eye tracking is disabled that the lights on the eye tracker is off – if there is no client application to the EyeX Engine running, the lights will also be switched off.
09/06/2015 at 14:10 #3097Vardan MeliksetyanParticipantThank you Jenny.
22/11/2016 at 17:18 #5971CarlosParticipantHello,
How can I check if eye tracking is disabled with C API? I can’t find an equivalent function.
Thank you24/11/2016 at 12:49 #5978Grant [Tobii]KeymasterHi @cchirive,
IF you check out Page 11 of the Developers Guide for EyeX SDK in C/C++, there we discuss the Connection State which I think should be suitable for your needs.
24/11/2016 at 13:17 #5979CarlosParticipantHi,
I’m working with C examples you provide, I’ve already seen how “txEnableConnection” function works, but with this I don’t know if EyeX is enabled or not.
The connection is stablished and EyeX state changes to TX_CONNECTIONSTATE_CONNECTED even if EyeX is has been disabled by user.30/11/2016 at 18:48 #5991Grant [Tobii]KeymasterHi @cchirive,
Sorry for the delay. We do indeed have something similar which is is mentioned on page 28 of the Developer’s Guide and how to use it is exemplified in the MinimalStatusNotifications sample.
I suggest you look at the TX_STATEPATH_EYETRACKINGSTATE in the MinimalStatusNotifications.c file.
01/12/2016 at 18:00 #5996CarlosParticipantHi,
It works fine
Thanks05/12/2016 at 21:31 #6008Grant [Tobii]KeymasterGreat, thanks for the update.
13/06/2017 at 12:44 #7031GoodSpeedParticipantany update this method in the new sdk?
15/06/2017 at 22:22 #7050Grant [Tobii]KeymasterHi @guspid, the function is still available in the latest iterations of the SDK for Unity, .NET. To what flavor were you referring?
- AuthorPosts
- You must be logged in to reply to this topic.