本文介绍了编程转换SVG图形为路径(了lineTo,通过MoveTo)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个从Inkscape中,Illustrator或任何其他应用程序来SVG文件。我想形状为了lineTo 通过MoveTo curveto 格式。

I have an SVG file coming from Inkscape, Illustrator, or any other application. I want to convert the shapes to lineto, moveto, curveto format.

我想是这样的:

./Appname svgfile outfilewithpath

我会给SVG文件作为参数,然后我的应用程序将对象转换成相应的路径。

I will give the SVG file as an argument, then my application will convert the object into the respective paths.

推荐答案

Inkscape中有一个命令行界面。使用:

Inkscape has a command-line interface. Use the Inkscape man page along with the verb source for reference:

ObjectToPath 动词的对象转换为路径:

The ObjectToPath verb converts an object to a path:

inkscape filename.svg --select=myobject --verb=ObjectToPath --export-plain-svg=filename_to_path.svg

导出文本到路径参数文本节点转换为路径:

The export-text-to-path argument converts text nodes to paths:

inkscape filename.svg --export-eps=filename.eps --export-text-to-path

以上是关于如何在Perl和Ruby,PHP或者Python运行Inkscape中相关的问题:

These are related questions on how to run InkScape from Perl, Ruby, PHP or Python:


  • 的Inkscape中壳



  • Using the Inkscape shell from perl
  • Run inkscape in PHP
  • Calling Inkscape in Python
  • Inkscape Merge Ruby Gem

这篇关于编程转换SVG图形为路径(了lineTo,通过MoveTo)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-31 02:48