CaptureToBitmap with TransparentBackground


I’ve some trouble with CaptureToBitmap, I use a conduit (c#)

PreDrawObjects(DrawEventArgs e)
DisplayMaterial MyMaterial = new Rhino.Display.DisplayMaterial(Color.Red);
e.Display.DrawBrepShaded(brep, MyMaterial);          
e.Display.Draw3dText(MyText, Color.Black, plan);

ViewCapture.TransparentBackground = false, it is Ok, Brep RED and Drawtext BLACK in the bitmap

ViewCapture.TransparentBackground = true, Brep and Drawtext are WHITE in the bitmap

Did I miss something ?


I test with RhinoCommon or in Rhino command ‘Capture viewport to file’ and it show that TransparentBackground affect the result when there is display conduit actif. All what draw in the conduit will be white.
My problem is to avoid a color background for printing when capture the screen when a conduit is actif.
I’m looking for a workaround.
Anybody have an idea to set a white background and switch back to the original background color after screen capture with Rhinocommon.

Sorry for every body spend time to read it