About building the NetStim extension

Operating system: win 10
Slicer version: 4.13
Expected behavior: expect to build NetStim
Actual behavior: failed
Hi everyone, I am Dr. Lin. I have to seek for help here because I have been stuck in building of Slicer and extension for a month.
I am interested in the new software Lead OR which is developed by the famous lead DBS team. Lead OR is part of the NetStim extension. So I first built Slicer from source, and Slicer can run without an error, and it seems standard functions and modules are installed. Then I built the NetStim extension according to instructions on its website. I also installed the SDK provided by our local Alpha Omega distributor. However, I can only see the NetStim extension, with Import Atlas, Lead OR, Stereotactic plan, Warp Drive modules, which is similar to the functions installed directly from the extension manager. The most important Alpha Omega module is missing.

We start Slicer using SlicerWithSlicerNetstim.exe, install depend extension(MarkupsToModel, SlicerRT), wrapDriver could be selected, but could not find the alphaomega entry.
log shows " Cannot load library C:\D\E\NetstimReleaseWithAlphaomega\lib\Slicer-4.13\qt-loadable-modules\Release\qSlicerAlphaOmegaModule.dll"

We tried to rebuild the NetStim extension, with shorter folder path (C:\D\E\SNSR), but the error still exists when running SlicerWithSlicerNetstim.exe.
Cannot load library C:\D\E\SNSR\lib\Slicer-4.13\qt-loadable-modules\Release\qSlicerAlphaOmegaModule.dll

In the plugin modules dir, I get some dll files include qSlicerAlphaOmegaModule, Did I build alphaomega plugin correctly?

Any suggestions for me on how to enable Alpha Omega function, or how to proceed from here?
Thanks a lot!

I don’t think there are a lot of people who have experience building that particular extension so you will probably need to ask the extension developers directly. One thing you might try is to use Process Monitor to track what it’s trying to access right before the error message. It might be looking for another dependency that’s not in the path. Otherwise it might perhaps be a locale issue if something in the path has non-latin characters.

1 Like

You need to manually enable building of the AlphaOmega module by uncommenting this line:

Probably you have figured this out already, because you have the qSlicerAlphaOmegaModule.dll.

The module folder should only contain module DLLs. Third-party DLLs can go to the module’s bin folder in the install tree. In the build tree, you can make sure a third-party DLL (NeuroOmega_x64.dll) is found by copying it in the same folder as SlicerApp-real.exe (c:\D\S4R\Slicer-build\bin\Release).

Next week is Slicer Project Week. It is exactly for solving this kind of problems. I would recommend to contact Simon Oxenford @simonoxen to see if he can help you during the week.

1 Like

Thanks @pieper and @lassoan. We’ve been in contact already and got to this point explained here. I suggested to post on discourse to get more suggestions. Wanted to comment this before but only read this now.

Thanks! perhaps this makes some kind of issue, I’ll fix it.

@Lin This is a good pointer to try to debug on your side.

Thanks again!

Thank you all for taking your time to give suggestions and share experiences. The reason I am so interested in this is that I think the software is amazing. I’ll try your advice and get back to you soon. Thanks a lot.

1 Like

@pieper We used Process Monitor to track all loading behaviors of Slicer, including lib, exe and dll files, see Fig 1.

@lassoan Yes, We’ve uncommented the line in the CmakeList file.

We also dumped the alphaomega dll file. See the files here.

and log (http://stella2018.myqnapcloud.cn:5000/share.cgi?ssid=3e53ae7011b843b790cb4e722bb35101)
We compared the results from the monitor and the results from dep lip (dump), and found that these files were not load in the Slicer.
We confirmed that these dll files exist in the windows we are using. And we copies these files to the folder of Alpha Omega module, but the issue resumed.
We are not sure why these files are not loaded, and whether it is responsible to my issue here. Just to let you know what we found, hope useful.
Many thanks to you all! @lassoan @simonoxen @pieper

Many DLL loading errors can be discovered using Dependency Walker. Launch Dependency Walker using Slicer.exe --launch path/to/depends.exe and drag-and-drop the DLL that fails to load. Dependency walker was created before side-by-side assemblies existed, so there are always some false positives (api-ms-win-crt… and the like are usually false positives, you don’t need to worry about them).

If Dependency Walker does not uncover anything useful then you need to use sxstrace tool. See instructions here.

1 Like

Hi all, after a long time of moving back and forth, with the help of my two friends, Alpha Omega module is finally installed. There was a package missing, which was Microsoft Visuala C++ 2019, redistributiable package. We installed it manually, then it finally got through. I can now connect to Neuro Omega, although I still do not know how to use the software.
Thank you all for suggestions! @pieper @lassoan @simonoxen

BTW, is there any sort of specification manual or similar?

1 Like

Still working on a demonstrative video and better documentation. There is some info on the repo and the manuscript.

1 Like