Home › Forums › Software Development › Can't Get Basic C++ Example Working
Tagged: access violation, sample
- This topic has 5 replies, 2 voices, and was last updated 3 years ago by Grant [Tobii].
- 19/03/2020 at 22:49 #14048
I just started trying to work with tobii’s stream engine api, and I can’t get the basic C++ example (https://developer.tobii.com/consumer-eye-trackers/stream-engine/getting-started/) working in Visual Studio. One issue is that the NuGet package version seems to be simply broken – it’s missing things like TOBII_FIELD_OF_USE_INTERACTIVE in tobii.h. Since the downloadable zip version has that, that’s an easy workaround (that might still want to see some official attention).
The more serious issue is with tobii_stream_engine.dll. Apparently it likes writing to 0x00000001, which is not good.
Unhandled exception at 0x79F63CE5 (tobii_stream_engine.dll) in EyeMouse.exe: 0xC0000005: Access violation writing location 0x00000001. occurred
This occurs at the following line:
result = tobii_device_create(api, url, TOBII_FIELD_OF_USE_INTERACTIVE, &device);
Given that the code up to that point is literally copy-pasted from the example, I’m rather concerned. Does anyone have any potential solutions?20/03/2020 at 12:45 #14052
Hi @jraizes, sorry to hear about your issues and thanks for letting us know. Firstly, could you kindly confirm which version of Visual Studio and the Stream Engine you are using please?
The more details you can provide (including system specs and Tobii Tracker model), the better we will be able to attempt to reproduce the issue and hopefully issue a prompt fix. Thanks for your understanding and apologies for any inconvenience.20/03/2020 at 16:23 #14053
I am using Visual Studio 2017 version 15.7.6 on Windows 10. My eye tracker is a Tobii 4c. The stream engine dll version is 184.108.40.206/03/2020 at 11:53 #14055
Hi @jraizes, thanks for that. You are using a very old version of the Stream Engine as supplied via Nuget (V2.2.2). Until we update the Nuget repository to match the most recent version (v4.1.0) please download the dedicated source ZIP files from the getting started page @ https://developer.tobii.com/consumer-eye-trackers/stream-engine/getting-started/ and let us know if the issue persists.23/03/2020 at 16:10 #14056
Thanks, that fixed the issue (once I figured out that VS had cached and was continuing to use the DLL from NuGet despite me having explicitly uninstalled the package from NuGet….)23/03/2020 at 18:28 #14057
Great! Please do let us know if we can provide you with any further assistance. Best Wishes.
- You must be logged in to reply to this topic.