Rhino.Inside and Intersection Method

Dear Forum users,

I would like to obtain a CurveIntersections class type object resulted from utilizing Rhino.Geometry.Intersect.Intersection.CurveSurface( ) method. This method gives the intersection info resulted in the intersection of a Curve and Surface.

However, I use a standalone C# console project. @menno advised me to purchase Rhino v.8 license and use Rhino.Inside in which more complicated Rhino methods could be called from a console. In this way, I have purchased Rhino v8 and downloaded RhinoInside with NuGet package.

Later, I have written a C# code as:

using Rhino.FileIO;
using Rhino.Geometry;
using Rhino.DocObjects;
using Rhino.Collections;
using Rhino.Geometry.Collections;
using RhinoInside; 

class Program
{
    [STAThread]
    public static void Main(string[] args)
    {

        Resolver.UseLatest = true;
        Resolver.Initialize();

        string str2 = "C:\\Users\\SAMSUNG\\Desktop\\C#-Rhino\\Case3yeni4.3dm";
        File3dm file3dm = File3dm.Read(str2);

       Rhino.Geometry.Intersect.Intersection.

However, I still cannot see Rhino.Geometry.Intersect.Intersection.CurveSurface ( ) method from the list Visual Studio suggested.

While loading Rhino.Inside from NuGet package, I get a warning code no: MSB3270

The warning code is as:

warning MSB3270: There was a mismatch between the processor architecture of the project being built “MSIL” and the processor architecture of the reference “C:\Users\SAMSUNG.nuget\packages\rhino.inside\7.0.0\lib\net48\RhinoInside.dll” This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project.

Could this warning be the reason that I still cannot see the CurveSurface( ) method from the suggestion list or am I missing something?

I really appreciate for your help.

Best Regards,

Ahmet

Dear Forum users,

I have solved the problem. The reason is that I could not correctly downloaded Rhino.Inside since the target framework I have used in Visual Studio is .Net8.0. Since Rhino.Inside lastly arranged by .NET Framework 4.8, I need to change my target framework by right clicking my project name in the solution panel, go to properties and then changed the target framework into .NET Framework 4.8 instead of .NET 8.0. Later, I uninstalled Rhino.Inside and then re-installed and now it captures all methods of RhinoCommon.

Thank you @menno for your leading. I appreciate for that.

1 Like