DisplayConduit, Thanks, it's Great!

Just a thank you for the implementation of this. I’d expected doing some manual display overrides to be hard, but it’s this easy:
(where a ForEach-able container of items is supplied externally)

        protected override void DrawForeground(Rhino.Display.DrawEventArgs e)
        {
            foreach (GeometryBase itm in items)
            {
                System.Drawing.Color clr = System.Drawing.Color.Red;
                Rhino.Display.DisplayPen pen = new Rhino.Display.DisplayPen();
                pen.Color = clr;
                pen.Thickness = 3;
                if (itm is Curve)
                {
                    e.Display.DrawCurve((Curve) itm, pen);
                 }
            }
        }
1 Like

Nice example :slight_smile:
Small tip: I think you should be able to define the DisplayPen object once, outside the foreach loop.

Thanks. It’s the one I’d been looking for so I provided it :slight_smile:

I will be defining the color and pen outside of the function: I just wanted this example to be self-contained.

The only fly in the ointment here is that SubDFace and SubDEdge don’t inherit from GeometryBase (either directly or through SubDComponent). That also means a call to GeometryEquals is out.