Export Pdf with controllable point object size

Hi everyone, I am looking for a way to export pdf with a proper control over the display.
So far so good for exporting a pdf, but I am struggling a bit with the point size.

Here a sample of the code I am using (with no effect on point size) :

private static void ExportPdf(RhinoPageView view, string folderPath, float pointRadius, int dpi = 300)
// this is not working obviously, but I am short in idea to solve this.
         view.ActiveViewport.DisplayMode.DisplayAttributes.PointRadius = pointRadius;
         Rhino.FileIO.FilePdf pdf = Rhino.FileIO.FilePdf.Create();
        var settings = new ViewCaptureSettings(view, dpi);
        string filename = $"{folderPath}//{view.PageName}.pdf";

Hoping someone could help,

PS : the equivalent of the function I would like to use is the one in the printing windows about non scaling object.

Hi @Tristan_Gobin,

To change the point side of the current display mode, you can do something like this:

var display_mode = view.ActiveViewport.DisplayMode;
var old_radius = display_mode.DisplayAttributes.PointRadius;
display_mode.DisplayAttributes.PointRadius = radius;

However, something is up with the FilePdf ignoring some display mode settings. I’ve logged a issue for this.


– Dale

Thank you very much Dale. I will wait for a fix then.
Keep up the good work, it always a pleasure to work with Rhino.

RH-52835 is fixed in the latest Service Release Candidate

1 Like