Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to make it works in unity and show in Hololens 2? #46

Open
Hans86 opened this issue Sep 8, 2022 · 9 comments
Open

How to make it works in unity and show in Hololens 2? #46

Hans86 opened this issue Sep 8, 2022 · 9 comments

Comments

@Hans86
Copy link

Hans86 commented Sep 8, 2022

Thanks for author's project. When i try to follow the steps to put the .dll and .winmd into my unity project, it didn't show the depth camera view in hololens.

My hololens just show the view that i built before, but there is no any error msg, what's wrong with this situation, do i need to do anything to activate the .dll?

@Mt-Perazim
Copy link

what is your dll-path in your project?
do you see the dll in the builded project in the solution explrorer of visual studio?
did you enable developer mode and research mode on you hololens?
did you set the capabilities the right way?
starting the application the first time, do you get the typical notifications/questions about capabilities?

You are providing no information...

@Hans86
Copy link
Author

Hans86 commented Sep 12, 2022

I built author's .sln to get the .dll and .winmd, then I put them into my unity project, and the path is Assets/Plugins/WSA/ARM64.
image
I'm sure that I turn on the mode because I have run the Microsoft sample project and it can be run.
After I built my project, it looks success and there's no any error notification.
image
image
Should I change any setting about these two files?Thanks for your help.

@Mt-Perazim
Copy link

Those settings are ok.
What version of unity are you using?
What XR Plugin-in Managment are you using? (Windows Mixed Reality or OpenXR)

@Hans86
Copy link
Author

Hans86 commented Sep 13, 2022

The version I use is 2020.3.14f, I try to use the version that author provide has these problem.
image

My XR Plugin-in Management is OpenXR and feature group is set to Microsoft Hololens like this.
image

@Mt-Perazim
Copy link

Mt-Perazim commented Sep 13, 2022

You have to work with Windows Mixed Reality. Remove OpenXR.

As for the path error, I can't tell you exactly what your problem is. Maybe your path is too long? There was a issue in some unity versions with the length of a path.

@Hans86
Copy link
Author

Hans86 commented Sep 13, 2022

I tried to use Windows Mixed Reality,but it still not work.
image

After put two data in Plugins, should I do anything else?

Appreciate to your reply, I'll try to find wether the path is too long.

@Mt-Perazim
Copy link

if you followed the instruction for this plugin, there nothing else you have to do. It should work.
Did you setup the manifest file the right way?

@Hans86
Copy link
Author

Hans86 commented Sep 15, 2022

I think I followed the instruction, is it possible to have your successful project, I don't know what happen to my project.

@petergu684
Copy link
Owner

I know it has been long but anyway. The built DLL and winmd files just give you an interface (basically functions that you can call) to access the research mode sensor data via C# script. Putting these two files directly in your own Unity project won't show you anything: you need to write your own C# script and configure materials and shaders in Unity if you want to visualize it. The UnitySample folder showed a sample Unity project on how to do that, though I guess you don't have to visualize the images in your own app if you are just interested in its computer vision applications. If you are only interested in streaming sensor data to laptop, the psi project is definitely easier to use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants