Rhino C++ SDK - install Visual Studio 2022

Hello everyone!

I would like to ask for assistance on installing the C++ SDK to projects using Visual Studio 2022. The issue is that the installer asks that VS2019 be installed, which is annoying…

The main use case is that I have a C# plugin. Some operations (not using Rhino) are done in native code using marshalling. I wrapped the functionality in a C++ library and I marshall the calls from/to C#.
But there are some operations that call/use Rhino objects that I would like to keep on the C++ side (currently they are brought back to the managed C# side…).

For this, I need my C++ library project to link to the Rhino C++ SDK - so that I can have one library to rule them all!

It would be amazing to have VSPKG support :slight_smile:


Hi @scudelari,

To build C++ plug-ins for Rhino 7, you need Visual Studio 2019.

You can use VS 2022, as long as you have the VS 2019 platform toolset installed.

I assume you mean vcpkg. The Rhino C/C++ SDK provides pre-build binaries, so I’m not seeing how vcpkg would fit in. How would you see this working?

– Dale

Hi @dale ,

Indeed I meant vcpkg - sorry.

It does accept packages that are pre-built private binaries such as it would be for Rhino.
Check the FAQ: https://vcpkg.readthedocs.io/en/latest/about/faq/

Can I use a prebuilt private library with this tool?

Yes. The portfile.cmake for a library is fundamentally a script that places the headers and binaries into the correct arrangement in the ${CURRENT_PACKAGES_DIR}, so to pull in prebuilt binaries you can write a portfile which directly downloads and arranges the files.

To see an example of this, look at ports\opengl\portfile.cmake which simply copies files out of the Windows SDK.

I find it great, and it really does solve the problem of finding and linking dependencies in windows when using Visual Studio. The packages are magically available to any C++ project in Visual Studio and you can simply add the include of the header file you need.

In my local machine I can see the header files in the C:\src\vcpkg\installed\x64-windows\include folder, the lib files in the C:\src\vcpkg\installed\x64-windows\lib and the .dll/.pdb in the C:\src\vcpkg\installed\x64-windows\bin folder.

It feels to me that it could make sense to add the Rhino SDK to the tool. Perhaps this could become a feature request?

Thank you!

Hi @dale,
Sorry to annoy, but do you think there is any chance this could be considered?

1 Like

Second this post.
VS2022 has been out for a while and not able to create a Rhino C/C++ project from VS2022 is really not convenient.