Very simple SVG to PNG converter library using the Inkscape.

Go Report Card

svg2png

Description

Very simple SVG to PNG converter library using the Inkscape.

Installation

go get github.com/mskrha/svg2png

Usage

package main

import (
	"fmt"

	"github.com/mskrha/svg2png"
)

func main() {
	var input []byte

	// Fill the input with SVG image

	converter := svg2png.New()

	output, err := converter.Convert(input)
	if err != nil {
		fmt.Println(err)
		return
	}

	// Read the output PNG image
}
Similar Resources

Cairo in Go: vector to SVG, PDF, EPS, raster, HTML Canvas, etc.

Cairo in Go: vector to SVG, PDF, EPS, raster, HTML Canvas, etc.

Canvas is a common vector drawing target that can output SVG, PDF, EPS, raster images (PNG, JPG, GIF, ...), HTML Canvas through WASM, and OpenGL. It h

Dec 25, 2022

gensvg generates SVG to an io.Writer

gensvg generates SVG to an io.Writer

gensvg: A Go library for SVG generation The library generates SVG as defined by the Scalable Vector Graphics 1.1 Specification

Dec 28, 2022

Go-binsize-treemap - Go binary size SVG treemap

🔍 Go binary size SVG treemap Make treemap breakdown of Go executable binary $ g

Dec 21, 2022

JPEG-MPO Decoder / Converter Library and CLI Tool

MPO Decoder Library Simple Go JPEG MPO (Multi Picture Object) Decoder - Library and CLI Tool The library and CLI tool contain the ability to convert M

Sep 26, 2022

A (very) simple graph package that utilizes the Generics features in Go 1.18

A (very) simple graph package that utilizes the Generics features in Go 1.18

May 11, 2022

Generate image plots of processes' memory usage very quickly, within a single binary.

Generate image plots of processes' memory usage very quickly, within a single binary.

memplot A small utility written in golang to quickly plot memory usage of processes. memplot constantly samples memory usage of a process, for a given

Apr 17, 2021

📸 Clean your image folder using perceptual hashing and BK-trees using Go!

📸 Clean your image folder using perceptual hashing and BK-trees using Go!

Image Cleaner 🏞 🏞 ➡ 🏞 This tool can take your image gallery and create a new folder with image-alike-cluster folders. It uses a perceptual image ha

Oct 8, 2022

go-pix is a Go library for generating Pix transactions using Copy and Paste or QR codes. 💳 💰

go-pix is a Go library for generating Pix transactions using Copy and Paste or QR codes. 💳 💰

go-pix go-pix is a Go library for generating Pix transactions using Copy and Paste or QR codes.

Sep 12, 2022

A festive Christmas tree GIF generator implemented using only Golang standard library code

A festive Christmas tree GIF generator implemented using only Golang standard library code

Christmas Tree GIF Generator A festive Christmas tree GIF generator implemented

Feb 4, 2022
Comments
  • Fix Inkscape CLI options

    Fix Inkscape CLI options

    Inkscape's CLI options have changed since this was written, which broke it. The Inkscape CLI wiki page has the changes listed. This should have the same behavior, but I'm not an Inkscape expert. I tested it with a few SVGs I had lying around and it worked for all of them, which is a very professional and thorough testing method ;)

Related tags
Simple ANSi to PNG converter written in pure Go

AnsiGo Description AnsiGo is a simple ANSi to PNG converter written in pure Go. It converts files containing ANSi sequences (.ANS) into PNG images. Fo

May 17, 2022
A Free 8-Bit Sprite Generator. Create 256 variants from a single template .PNG
A Free 8-Bit Sprite Generator.  Create 256 variants from a single template .PNG

BitSprite A Free 8-Bit Sprite Generator. What? BitSprite is a program that creates variants of an image across total sprite sheet of the resultant ima

Sep 20, 2022
Paprika is a toolbox for creating short clips from multiple png files.
Paprika is a toolbox for creating short clips from multiple png files.

Paprika Paprika is a toolbox for creating short clips from multiple png files. Requirements This program is mainly a wrapper around ffmpeg. As such, y

Feb 16, 2022
Image size analyzer for jpg/png/gif/webp

imgsz Image size analyzer for jpg/png/gif/webp Usage // DecodeSize decodes the dimensions of an image that has // been encoded in a registered format.

Jan 8, 2022
Go-Generative-Art-A - Generate PNG art from source images! GOLang Generative Art
Go-Generative-Art-A - Generate PNG art from source images! GOLang Generative Art

GO Lang Generative Art Tool A Take source images and generate art utilizing sour

Nov 21, 2022
Go Language Library for SVG generation
Go Language Library for SVG generation

SVGo: A Go library for SVG generation The library generates SVG as defined by the Scalable Vector Graphics 1.1 Specification (http://www.w3.org/TR/SVG

Jan 6, 2023
A simple API written in Go that creates badges in SVG format, based on the requested route.

A simple API written in Go that creates badges in SVG format, based on the requested route. Those graphics can be used to style README.md files, or to add tags to webpages.

Jul 2, 2021
Canvas is a Go drawing library based on OpenGL or using software rendering that is very similar to the HTML5 canvas API
Canvas is a Go drawing library based on OpenGL or using software rendering that is very similar to the HTML5 canvas API

Go canvas Canvas is a pure Go library that provides drawing functionality as similar as possible to the HTML5 canvas API. It has nothing to do with HT

Jan 3, 2023
2D rendering for different output (raster, pdf, svg)
2D rendering for different output (raster, pdf, svg)

draw2d Package draw2d is a go 2D vector graphics library with support for multiple outputs such as images (draw2d), pdf documents (draw2dpdf), opengl

Dec 25, 2022
Rasterx is an SVG 2.0 path compliant rasterizer that can use either the golang vector or a derivative of the freetype anti-aliaser.
Rasterx is an SVG 2.0 path compliant rasterizer that can use either the golang vector or a derivative of the freetype anti-aliaser.

rasterx Rasterx is a golang rasterizer that implements path stroking functions capable of SVG 2.0 compliant 'arc' joins and explicit loop closing. Pat

Nov 1, 2022