OpenNurbs cpp solution build error

Hi @dale ,
I have downloaded the solution from the repo rhinocommon/dotnet/opennurbs at master · mcneel/rhinocommon · GitHub,
and I tried to build the solution, but it does not contain some header files or libraries. Could you please provide a solution to build the solution?

Query:
A: After a successful build of the C++ project, using the wrapper project, will I be able to call functions like the below sample from a C# project?

B: What if I have Rhino installed, or if I don’t have Rhino installed on my machine? Will the above solution execute without errors?

FYR
image

1 Like

You’re looking at the wrong repository. You should look at GitHub - mcneel/rhino3dm: Libraries based on OpenNURBS with a RhinoCommon style - this contains the dotnet library under src/ as well. You’ll find all the necessary build information and solutions in this repository.

Even better yet, instead of building your own libraries you can use the one that we publish to Nuget: NuGet Gallery | Rhino3dm 8.9.0

1 Like

Thanks for the update @nathanletwory , but compile error i could able to see, is that configuration to be set ? if so kindly suggest.

@fraguada are there any known issues with building current dotnet in rhino3dm?

@nathanletwory FYI, i have downloaded the dev branch

Well, that currently is not in a buildable state. Make sure to use the main branch. Or better, use the prebuilt Nuget package…

1 Like

Sure.
Prebuilt nugget packages of OpenNurbs does not contains few features like SubD.ToBrep, Surface.ToPullBack(), where as in our rhino SDK we have those methods.

In a nutshell, i am trying to use the rhinoSDK to call those methods.

If you want to use the full Rhino SDK you need to be using RhinoCommon, and that will work only when you have also Rhino installed, and running from inside Rhino.

Rhino3dm is mostly just a wrapper around OpenNURBS the file format part. Access to the geometry kernel is not part of that. Yes, you get to directly manipulate geometry, but you won’t for instance get access to boolean operations, etc. Even building your own version will not work without Rhino installed and running from inside Rhino.

Yes, I have rhino Installed. Instead of RhinoCommon, possible to use directly the sdk and its methods?

the term “running from inside” i understand is that, without opening rhino we can’t use those methods?

RhinoCommon is the SDK to use in a C# project.

correct.

thanks for the detailed information :slight_smile:

the same compile error throws in the main branch as well. can you suggest me the solution to build it.

Are you following the steps in rhino3dm/script at main · mcneel/rhino3dm · GitHub ?

Again, this repository will not give you the Rhino SDK, even if you build it yourself. The Rhino SDK to use for C# projects is RhinoCommon.


ok I got it, so there is no option to connect to methods from Opennurbs or any solution provided from Rhino, except RhinoCommon C#.

The only way to connect to all methods is RhinoCommon, no c++, no wrapper to contact with, even I have rhino licensed version?

RhinoCommon does wrap also OpenNURBS. RhinoCommon wraps the entire Rhino SDK, that includes OpenNURBS access.

You can use just the C++ Rhino SDK, of course. That doesn’t need custom compiling either, you can see installation instructions here: Rhino - Installing Tools (Windows) . But then you’ll have to do all the C++ and .NET interop yourself, which has already been done for you in RhinoCommon.

2 Likes

Does this c++ Rhino SDK can be used in an standalone application?

No, the full C++ Rhino SDK works only when run inside Rhino. This SDK and the .NET RhinoCommon SDK allow you to create plug-ins for Rhino.

For stand-alone applications you can use the public OpenNURBS library. The pure C++ version has the same restrictions as the rhino3dm versions - these are just a wrapper around the C++ version.

See for more information our guides: Rhino - Guides .

Plug-ins using the full SDK:
RhinoCommon: Rhino - Guides
C++ SDK: Rhino - Guides

Stand-alone apps using the file format SDK:
OpenNURBS and rhino3dm: Rhino - Guides

1 Like

thanks for the Comprehensive response!


so there is no way to connect from an standalone app(exe) to the plugin source(assume its running). ultimately to utilize the limited features in the opennurbs from plugin solution(full sdk).

To access Rhino from outside you can either use Compute ( Rhino - Compute: Features ) or use directly Rhino Inside technology ( GitHub - mcneel/rhino.inside: Sample Projects for Rhino.Inside ).

In both cases a Rhino license is required - for Compute core-hour billing, for Rhino Inside a regular license.