Aspose.SVG.Drawing.SkiaSharp – Enhanced SVG Drawing and Conversion

Aspose.SVG.Drawing.SkiaSharp is a powerful extension component for Aspose.SVG for .NET that expands its functionality by leveraging the SkiaSharp library for drawing and comprehensive conversion of SVG files. This extension enhances the capabilities of Aspose.SVG for .NET by providing seamless integration with SkiaSharp’s advanced features, resulting in faster drawing, high-quality rendering, and versatile SVG conversion options.

Key Features

Discover how Aspose.SVG.Drawing.SkiaSharp enhances the functionality of Aspose.SVG for .NET by leveraging the SkiaSharp library for drawing and comprehensive conversion of SVG files. Convert SVG files to popular raster formats and leverage advanced image filters, shaders, and effects for visually enhanced graphics. Seamlessly integrate SkiaSharp into your .NET Apps and enjoy faster drawing capabilities and multiplatform support. Explore the key features and learn how to activate this powerful feature with a simple code snippet.

Comprehensive SVG Conversion

Enhanced Drawing Capabilities

Multiplatform Support

Using Aspose.SVG.Drawing.SkiaSharp for .NET on Linux will require installing an additional NuGet package containing the corresponding native assets, here are some of them:

Example of Using Aspose.SVG.Drawing.SkiaSharp

To activate the Aspose.SVG.Drawing.SkiaSharp feature, simply include the following code snippet in your application:

1Aspose.Svg.Configuration.SetExtension(new SkiaModule());

After activating this feature, all SVG document conversions and drawings will be performed using the SkiaSharp library, leveraging its powerful capabilities for enhanced rendering and conversion. Here’s an illustration on how to convert SVG files to PNG:

 1using Aspose.Svg;
 2using System.IO;
 3using Aspose.Svg.Saving;
 4using Aspose.Svg.Converters;
 5using Aspose.Svg.Drawing.SkiaSharp;
 6
 7    // Initilize SkiaSharp-based drawing engine
 8    Aspose.Svg.Configuration.SetExtension(new SkiaModule());
 9
10    // Initialize an SVG document from a file
11    using (var document = new SVGDocument(Path.Combine(DataDir, "source.svg")))
12    {
13        // Create an instance of the ImageSaveOptions class
14        var pngSaveOptions = new ImageSaveOptions();
15
16        // Convert SVG to PNG
17        Converter.ConvertSVG(document, pngSaveOptions, Path.Combine(OutputDir, "result.png"));
18    }

About SkiaSharp

SkiaSharp is an open-source 2D graphics API, stemming from Google’s Skia library. It is renowned for its high-quality rendering capabilities. By availing advanced graphics features and APIs, SkiaSharp is perfect for mobile apps, games, and even server applications.

Notice

The combination of Aspose.SVG and SkiaSharp through Aspose.SVG.Drawing.SkiaSharp empowers developers to deliver high-quality SVG rendering, advanced image effects, and comprehensive SVG conversion options, all while benefiting from the performance and flexibility provided by SkiaSharp and the rich functionality of Aspose.SVG for .NET.

Subscribe to Aspose Product Updates

Get monthly newsletters & offers directly delivered to your mailbox.