Overview - mcneel/Rhino.Inside-Workshop GitHub Wiki
This part of the masterclass will cover all of the topics relevant to the Rhino.Inside technology starting from a high level description of all of the aspects of the the technology, and the limitations that developers should be aware of when using the technology.
What is Rhino.Inside?
Rhino.Inside® is an open source Rhino WIP project which allows Rhino and Grasshopper to run inside other 64-bit Windows applications such as Revit, AutoCAD, etc. It is now possible to:
- Start Rhino and Grasshopper as an add-in to other applications.
- Drive the host application with Grasshopper definitions.
- Use the host's APIs in a Grasshopper and Rhino plug-in.
- Use Rhino's APIs in the host's plug-ins.
- Create native objects in the host application with Rhino and Grasshopper.
In which applications does Rhino.Inside currently run?
- Console Applications
- WinForms / ETO Applications
- Autodesk Revit
- Autodesk AutoCAD
- Bricsys BricsCAD
- CPython
- JavaScript (Node.js, Electron, CefSharp)
- Microsoft Excel
- Unity 3d
- Unreal Engine
- Others?
Here, Rhino.Inside.Revit is a special case where we've developed an 'implementation' with an installer.
What are the main requirements to getting Rhino.Inside to work in another application?
- The application must run on Windows.
- The application must be 64-bit.
- The application should have a .NET API.
- The application should use the .NET Runtime to execute plugin code.
Given these requirements, there are a few more situations where it might be difficult to get Rhino.Inside to work in a host application:
- The application's API isn't public.
- The application uses the Mono Runtime. This means that RhinoCommon will most likely work, but Grasshopper's API will not (although there are some ways around this in the works).
- The application uses custom AppDomains to load assemblies.
In some very special cases, we're trying this with host applications which only have a C++ API.
Masterclass Samples
- Sample-1: Getting Started with Rhino.Inside. This sample covers how to integrate all of the necessary code in to get Rhino.Inside working in a Console application.
- Sample-2: This sample shows the basic use of the RhinoWindows.dll, which includes a custom control for embedding a Rhino viewport into a WinForm or Eto application.
- Sample-3: Rhino.Inside Unreal Engine - Part 1. This sample covers how to get Rhino.Inside Unreal Engine and do some very basic operations. We will also look at how to expose C# functions to Unreal Engine Blueprints.
- Sample-4: Rhino.Inside Unreal Engine - Part 2. This sample covers how to get Rhino.Inside Unreal Engine and interact with the Grasshopper UI.