Hello, this is kinda newbie question but I need help
I am Mac user and trying to use iMSTK-Unity, and when I import the iMSTK asset error occurs
Assets/Imstk/Scripts/Devices/OpenHapticsDevice.cs(38,29): error CS0234: The type or namespace name ‘HapticDeviceManager’ does not exist in the namespace ‘Imstk’ (are you missing an assembly reference?)
I checked the READ ME and website for setup. What I understand is I need to use cmake and build the iMSTK.
I downloaded the cmake, made iMSTK_build (mkdir iMSTK_build)
but for the path. I am not sure what to put. Do I need to make seperate folder or I need to use the path of unity project? (Which path to put source code and which path to put build?)
then I also need cmakelists.txt. Do I need to make one?
I searched about cmake and checked other questions posted here, but I don’t think I understand this well.
Please help me. I just want to run sample scene and check it by Unity.
Hi Shiloh I’m away from my computer today but first up we haven’t neither tested imstk on the Mac nor the imstk Unity package, and we’re not really supporting it, you’ll be the first.
I’m only on the phone atm I should be able to give you a better answer tomorrow.
To lead off as i said we have neither tested imstk nor imstk unity on mac os, and we are currently not supporting it, I can get you started and help through the forum but we probably won’t be able to fix any issues that come up. There are 3 layers that need to work together for the fully functioning unity asset.
The iMSTK library itself
Swig generated C++ to C# wrapping code
The iMSTK-Unity library with the above installed
As we’re not supporting OSX you will probably have to know some CMAKE to make changes, you might also need to edit some of the C++ code if something breaks.
It would be great if you could use the main-version-2 branch of iMSTK-Unity it is the most up to date version and it’s what we are going to base the next release on. IMSTK-Unity has iMSTK as a subproject under the ImstkSource~ directory, use that source folder for building the binaries it is the correct version for that version of iMSTK-Unity.
I’d also install ccmake it’s a terminal GUI for cmake and will make handling cmake a bit easier. but once you’ve checked out the repository from above. You can do
cd <path to repo>/ImstkSource~/
mkdir iMSTK_build
cd iMSTK_build
cmake ../iMSTK
make -j4
If you have never worked with cmake i’d sugest looking at a few tutorials.
The line cmake ../iMSTK just means run cmake with the data found in the directory ../iMSTK which is the directory that was checked out from the repository. If you can run make and everything builds correctly that would be a good check, there is no reason for some of the other steps if this doesn’t work.
Sorry I missed your reply, you should turn off OpenHaptics and VRPN for testing. I attempted to build imstk on my mac but it was not fully building so i’m not sure if you have a complete build
The problem is that we haven’t tested iMSTK on OSX at all and you’re trying to go directly to unity. There are multiple layers that all need to work so that the overall unity integration works. The steps i would usually do is
Build iMSTK by itself :with test, with examples on, in your case without Openhaptics, without VRPN
Run the unit tests see if they are suceeding, run the examples see that they are working (the unit tests are more important than the examples) if they aren’t working, fix that before proceeding to the next step
Turn on C# wrapping, build the wrapping, build the C# examples see if those are working, if not analyse and fix
Now switch to BUILD_FOR_UNITY that turns off the examples and rendering, make sure to turn off VRPN, turn off Openhaptics.
All the binary files in the install folder need to go into the Unity plugins folder. But as i can’t build it sucessfully i can’t tell you which those actually are.
So step by step you need to resolve any of the issues that come up, issues could be the build process not succeeding, or the software not working. If you skip any of those steps you will really mostly just see the unity integration not working but not know why.