烟花PNG格式,有什么见解吗?有库吗?
最终目标是将烟花 png 文件中的页面导出为单独的图像。所以我有几个问题:
- 你知道有什么东西——库、应用程序——已经可以做到这一点了吗?
- 你有关于格式的信息吗?我认为他们将信息存储在专门的块中。我只是希望这些块的有效负载的格式不那么难弄清楚。
我还没有挖掘过任何烟花文件。我没有找到有关格式的信息,所以这是下一步,但我认为有人可能知道一点并节省我一些时间:)。
我希望(可能并非如此)每个页面都以 PNG 形式存储在单独的 IDAT 块中。不过,由于矢量功能,这种情况不太可能发生。也许他们在块中存储 svg 格式?
任何帮助或讨论表示赞赏。我计划在接下来的几天内深入研究这个问题。
Ben
编辑:这里有几件事:下面链接的超级用户帖子表明文件是 APNG。烟花文件不是 APNG。 APNG 包含动画块:acTL、fcTL、fdAT。除了 IDAT 块之外,Fireworks 还具有 prVW、mkBF、mkTS、mkBS、mkBT 块,但没有 APNG 块。
这里有一篇关于烟花 PNG 的非常扎实的文章: http:// newsgroup.xnview.com/viewtopic.php?f=35&t=20592#p86243
所以我想我需要知道这些块的作用以及如何解析它们。
The ultimate goal is to export the pages in a fireworks png file to individual images. So I have a couple questions:
- Do you know of anything -- library, application -- that does this already?
- Do you have any information on the format? They store their information in specialized chunks, I assume. I'm just hoping the format of those chunks' payload is not so difficult to figure out.
I have not dug into any fireworks files yet. I am finding no information on the format, so that is next step, but I figured someone may know a bit and save me some time :).
What I hope (and probably isnt the case) is that each page is stored as PNG in separate IDAT chunks. Unlikely, though, due to the vector capabilities. Maybe they store svg format in the chunks?
Any help or discussion is appreciated. I plan to dig into this in the next couple days.
Ben
EDIT: Here are a couple things: the linked superuser post below indicates the files are APNG. fireworks files are not APNG. APNG contains animation chunks: acTL, fcTL, fdAT. Fireworks has, in addition to the IDAT chunks, prVW, mkBF, mkTS, mkBS, mkBT chunks but none of the APNG chunks.
There is a pretty solid post here on fireworks PNGs: http://newsgroup.xnview.com/viewtopic.php?f=35&t=20592#p86243
So I suppose I need to know what these chunks do, and how to parse them.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我自己对 Adobe Fireworks 文件中的私有块类型进行的一些挖掘如下(假设 Python 切片表示法):
prVW(“缩略图预览?”)
mkBF
mkBS
mkBT
mkTS
Some digging I did on my own for the private chunk types in Adobe Fireworks files is as follows (assume Python slicing notation):
prVW ("thumbnail preview?")
mkBF
mkBS
mkBT
mkTS
有趣的问题。
如果您尝试编写一个获取 Fireworks PNG(APNG) 并保存页面的实用程序,那么它有多大帮助,但这里是:
您可以使用 Fireworks 中的“导出”菜单:文件 > >出口>页面到文件。
您也可以使用另存为选项并选择Photoshop PSD。
此选项将页面保留为 Photoshop 图层面板中的文件夹/组,
但它确实栅格化矢量形状。不过,如果您想解析,它可能会很方便
PSD 而不是 APNG(用于访问图像、页面)。
我编写了一个小脚本(主要使用 docs),它将当前打开的 Fireworks PNG 的 PSD 保存到您选择的文件夹中:
如果将其另存为 .jsf 文件,并在 Fireworks 中打开文档,您应该只需双击.jsf 文件。
另外,注意到有一个导出 PSD 扩展可用,它比我这里的小脚本有更多的选项。
如果您需要矢量形状,可以使用文件导出>; FXG 和图像,然后选择格式下方的所有页面。 FXG 是一种 xml 格式,并且可以使用规范。
华泰
Interesting question.
Don't how much it helps, if you're trying to write an utility that gets a Fireworks PNG(APNG) and saves the pages, but here goes:
You could use the Export menu in Fireworks: File > Export > Pages to Files.
Also you could use the Save as option and choose Photoshop PSD.
This option preserves the pages as folders/groups int the Photoshop Layers Panel,
but it does rasterize vector shapes. Still, it could be handy if you want to parse
a PSD instead of a APNG(to access images,pages).
I've put together a small script (mostly using the docs) which saves a PSD of your currently open Fireworks PNG to a folder you choose:
If you save this as a .jsf file, and have a document open in Fireworks, you should be able to just double click the .jsf file.
Also, noticed there's an Export PSD extension available, which has more options than my little script here.
If you need the vector shapes, you can use File Export > FXG and Images and choose All Pages bellow the format. FXG is an xml format, and the specs are available.
HTH