microsoft / HoloLens2ForCV

Sample code and documentation for using the Microsoft HoloLens 2 for Computer Vision research.
MIT License
490 stars 145 forks source link

Where is ResearchModeAPI.dll? #61

Open vicobill opened 3 years ago

vicobill commented 3 years ago

When I use LoadLibraryA("ResearchModeAPI") in UE4, and add UE4 dll search path "C:/Windows/System32/" manually, or LoadLibrary("C:/Windows/System32/ResearchModeAPI.dll"), it's failed!

So, what's the location of "ResearchModeAPI.dll", and how can I load this dll in UE4?

Help me please!

dakesse commented 3 years ago

In Unity you have to add the dll to the project (Assets/Plugins/). Don't you have to do that in UE4 as well? Linking DLLs > Unreal Engine Project

JiangTao100 commented 3 years ago

It seems that there is only a .h profile named "ResearchModeAPI", I wanna import it to Unity,too

dakesse commented 3 years ago

It seems that there is only a .h profile named "ResearchModeAPI", I wanna import it to Unity,too

There is no DLL, as this is a C++ project the header is sufficient. If you want to use the researchmode in Unity/C# you will need to build your own DLL based on the sample code. There are already some posts regarding this topic: #19, #31, #40

cod3monk3y commented 2 years ago

@dakesse Each of the four samples in this repo calls LoadLibraryA("ResearchModeAPI"), which suggests the area all attempting to load a DLL. But as you say, there is only a header file. See search results: https://github.com/microsoft/HoloLens2ForCV/search?q=LoadLibraryA