Home Forums Software Development [Solved] UE4Edtior-TobiiEyeX.dll issue Reply To: [Solved] UE4Edtior-TobiiEyeX.dll issue

#5247
Temaran
Participant

Tjena Jesper!

The “UE4Editor-TobiiEyeX.dll problem” is unfortunately a general problem when it comes to source code plugins in Unreal Engine. As each plugin dll will only work with specific versions of the engine. One solution we could do is offer dlls for all versions out there, but that would most likely become very confusing.

This is why it is recommended to build source plugins yourself. If you have team members who work in blueprint using the binary version of the engine (the one you can download through the Epic launcher) you can still let them use the same generated dll by simply checking it into source control (or distribute it to the team in some other way).

Now for your main problem!
Have you tried getting it to work for a blank template project? The build problem might be related to other code in the solution, so if it’s not working in a blank template, then most likely it’s a problem of the project structure.

To be able to build, much like it says in the readme, you need to:
* First download the plugin code and place it under MyProject/Plugins/TobiiEyeX/ . So directly under TobiiEyeX/ you should have folders like Source and ThirdParty and the TobiiEyeX.uplugin

* Download the C++ sdk package. Then under MyProject/Plugins/TobiiEyeX/ThirdParty/EyeX/ you should end up with an include and a lib folder. You should see header files under the include folder and .lib files and .dll files under the lib folder (both have several subdirectories, so you might have to dig a bit before you can see the actual files).

* Next, you need to reference the plugin module in your main game module. This is to tell the linker where to find symbols for the EyeX stuff. You can always just include the module headers anywhere to make the compiler happy (you should only ever include module headers in the public subfolder though), but the linker isn’t as amicable.
To do this, you need to add an import to your MyProject/Source/MyGame/MyGame.Build.cs file either to the PublicDependencyModuleNames or PrivateDependencyModuleNames depending on where you want the module linkage to be visible in your project. Your build file will already have a set of module imports specified, so just add it to the end of the initializer. Here is an example:
PublicDependencyModuleNames.AddRange(new string[] {
“Core”,
“CoreUObject”,
“Engine”,
“InputCore”,
“RHI”,
“TobiiEyeX”
});

* Finally, if you want to be able to produce a build of your project and you don’t want to have to copy the dll to the output folder yourself, that’s where the
RuntimeDependencies.Add(new RuntimeDependency(“$(ProjectDir)/Plugins/TobiiEyeX/ThirdParty/EyeX/lib/x64/Tobii.EyeX.Client.dll”));
becomes important. This also has to be done in the same project build file as the previous step.

After doing this, you should be able to include “IEyeXPlugin.h” in any of your project files and be able to compile and link!

We are also working on packaging our dlls in the plugin itself so that this type of setup will be easier in the future, but there are currently licensing problems that make it hard to do so. Hopefully we can resolve these soon!
Unfortunately, when it comes to the build file setup, this is just how the engine works, so we most likely won’t be able to automate this process.

If you’re still running into problems, please PM me and I’ll try to help you out over skype 🙂

Best regards,
Temaran