Write raster and vector graphics to EPS

EPS Filesystem Drawing Text

Saves raster and vector graphics to EPS format.

Сode Snippet

using (var writer = new EpsWriter("WriteRasterAndVectorGraphicsToEPS.eps", 800, 650))
using (var graphics = writer.GetGraphics())
{
    // Draw bitmap
    using (var bitmap = new Bitmap("Chicago.jpg"))
    {
        graphics.DrawImage(bitmap, 100f, 100f);
    }

    // Draw rectangle
    graphics.DrawRectangle(new Pen(RgbColor.Gray, 4f), 50f, 50f, 700f, 550f);

    // Draw text
    var font = graphics.CreateFont("Arial", 56f);
    var text = new PlainText("Confidential", font, new SolidBrush(RgbColor.OrangeRed), 400f, 340f, TextAlignment.Center);

    graphics.DrawText(text);
}

Input

Chicago.jpg

Output

WriteRasterAndVectorGraphicsToEPS.eps

Download

For AI-assisted development: Download Graphics Mill Code Samples XML Catalog