+1
Under review

Image exporters for headless environment

Francois Botha 4 years ago in New features updated 4 years ago 4

I need to generate plots, save them to images and embed them in emails, all in a Windows service app, i.e. I have no dependencies on any UI libraries. I'd prefer to keep it that way and I don't want to reference Windows Forms, WPF or one of the other UI frameworks.


It should be possible to export to PNG by using just System.Windows.Drawing and package that all up as e.g. OxyPlot.Headless.

Under review

It should be possible to include the PngExporter.cs and GraphicsRenderContext.cs (from the OxyPlot.WindowsForms project) - then you don´t need to reference System.Windows.Forms.

Yes, I've managed to do that, but my suggestion is to make it an official project, package it as a Nuget package and all the other nice perks that come with it. Then it will benefit a much broader audience.

Yes, we could do that if there is enough interest! I am a bit concerned about the number of projects and packages to maintain, but please create a github issue and we will see!

I'll create a PR with a headless proposal that contains the exporter classes. I'm not sure what else could go into a headless library.