mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 17:59:20 -04:00
New port: graphics/nanosvg: Simple C++ header-only SVG parser
This commit is contained in:
parent
799253d29d
commit
5b3a80c291
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=512502
4 changed files with 54 additions and 0 deletions
|
@ -572,6 +572,7 @@
|
||||||
SUBDIR += mxp
|
SUBDIR += mxp
|
||||||
SUBDIR += mypaint
|
SUBDIR += mypaint
|
||||||
SUBDIR += mypaint-brushes
|
SUBDIR += mypaint-brushes
|
||||||
|
SUBDIR += nanosvg
|
||||||
SUBDIR += nathive
|
SUBDIR += nathive
|
||||||
SUBDIR += netpbm
|
SUBDIR += netpbm
|
||||||
SUBDIR += nip2
|
SUBDIR += nip2
|
||||||
|
|
26
graphics/nanosvg/Makefile
Normal file
26
graphics/nanosvg/Makefile
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
# $FreeBSD$
|
||||||
|
|
||||||
|
PORTNAME= nanosvg
|
||||||
|
DISTVERSION= g20190422
|
||||||
|
CATEGORIES= graphics
|
||||||
|
|
||||||
|
MAINTAINER= yuri@FreeBSD.org
|
||||||
|
COMMENT= Simple C++ header-only SVG parser
|
||||||
|
|
||||||
|
LICENSE= ZLIB
|
||||||
|
LICENSE_FILE= ${WRKSRC}/LICENSE.txt
|
||||||
|
|
||||||
|
USE_GITHUB= yes
|
||||||
|
GH_ACCOUNT= memononen
|
||||||
|
GH_TAGNAME= 25241c5
|
||||||
|
|
||||||
|
NO_BUILD= yes
|
||||||
|
NO_ARCH= yes
|
||||||
|
|
||||||
|
PLIST_FILES= include/nanosvg.h include/nanosvgrast.h
|
||||||
|
|
||||||
|
do-install:
|
||||||
|
${INSTALL_DATA} ${WRKSRC}/src/nanosvg.h ${STAGEDIR}${PREFIX}/include
|
||||||
|
${INSTALL_DATA} ${WRKSRC}/src/nanosvgrast.h ${STAGEDIR}${PREFIX}/include
|
||||||
|
|
||||||
|
.include <bsd.port.mk>
|
3
graphics/nanosvg/distinfo
Normal file
3
graphics/nanosvg/distinfo
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
TIMESTAMP = 1569076700
|
||||||
|
SHA256 (memononen-nanosvg-g20190422-25241c5_GH0.tar.gz) = 288d134f078c7bcb6360df65ab8de10331f59f96d08cf9be25eee6cec0756e12
|
||||||
|
SIZE (memononen-nanosvg-g20190422-25241c5_GH0.tar.gz) = 295817
|
24
graphics/nanosvg/pkg-descr
Normal file
24
graphics/nanosvg/pkg-descr
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
NanoSVG is a simple stupid single-header-file SVG parse. The output of the
|
||||||
|
parser is a list of cubic bezier shapes.
|
||||||
|
|
||||||
|
The library suits well for anything from rendering scalable icons in your editor
|
||||||
|
application to prototyping a game.
|
||||||
|
|
||||||
|
NanoSVG supports a wide range of SVG features, but something may be missing,
|
||||||
|
feel free to create a pull request!
|
||||||
|
|
||||||
|
The shapes in the SVG images are transformed by the viewBox and converted to
|
||||||
|
specified units. That is, you should get the same looking data as your designed
|
||||||
|
in your favorite app.
|
||||||
|
|
||||||
|
NanoSVG can return the paths in few different units. For example if you want to
|
||||||
|
render an image, you may choose to get the paths in pixels, or if you are
|
||||||
|
feeding the data into a CNC-cutter, you may want to use millimeters.
|
||||||
|
|
||||||
|
The units passed to NanoSVG should be one of: 'px', 'pt', 'pc' 'mm', 'cm', or
|
||||||
|
'in'. DPI (dots-per-inch) controls how the unit conversion is done.
|
||||||
|
|
||||||
|
If you don't know or care about the units stuff, "px" and 96 should get you
|
||||||
|
going.
|
||||||
|
|
||||||
|
WWW: https://github.com/memononen/nanosvg
|
Loading…
Add table
Reference in a new issue