I’ve just started working with Rhino to develop a plugin that renders some custom geometry. At the moment I’ve created a class that extends Display Conduit that does visibility testing of my data and loads/unloads it from memory as appropriate (the data type is far too big to load into RAM all in one go!).
Currently I’m loading the data as standard Rhino data object types which has been ok to prove my plugin is working and doing what it should, however using these standard types does provide issues as they’re not really designed to handle what I’m drawing.
Therefore I’d like to get access to the OpenGL context so I can render the geometry with my own OpenGL code, which may include some custom shaders too.
As far as I’m aware C Sharp doesn’t ship with proper OpenGL support so I’ve downloaded OpenTK and built against it. I now have the full arsenal of OpenGL syntax available to me, however I need some kind of valid OpenGL window context to initialise it. I’ve now hit a blank as I’m not sure how to get that information from the Rhino SDK.
Has anybody else gone down this route with the RhinoCommon SDK, and if so how did you go about being able to write pure OpenGL within a plugin? Or… am I barking up the wrong tree completely and there’s a much simpler way to draw custom geometry?