寻找与 PSD 格式一起使用的 java 库

发布于 2024-08-13 15:57:38 字数 1539 浏览 7 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

幸福丶如此 2024-08-20 15:57:38

可能很晚了,但由于在搜索“java psd库”时此页面在谷歌上的排名相当高,我将分享我的经验。

-正如鲍里斯所说,java-psd-library 是只读的。
它无法读取最新的 CS4 格式。如果您发现打开 psd 文件时出错,在 Gimp 2.8 中打开它并再次保存可能会解决该问题。

- 由于我需要处理分层图形文件,我花了一些时间寻找替代方案。 PSD 格式是专有的,对规范的访问似乎受到限制。
我发现 OpenRaster 格式是一个非常好的替代方案: http://en.wikipedia.org/wiki/OpenRaster
它有开放的规格,而且非常简单。它是一个压缩文件,包含 png 图层和描述符文件。 Gimp 可以很好地处理这种格式,并且可以轻松地将 psd 文件导出到 ora 文件。
您可以找到一些 Java 工具来操作它们。它是一个更庞大的项目的一部分,该项目仍处于 Alpha 阶段:https://code.google.com/ p/mediaz/

希望它能帮助人们。

Probably very late, but as this page is pretty high ranked on google when searching "java psd library" I'll share my experience.

-As Boris said the java-psd-library is read only.
It has trouble reading recent CS4 format. If you ever find yourself with an error opening a psd file, opening it in Gimp 2.8 and saving it again will probably fix the issue.

-As I needed to work on layered graphic files, I took time to search for an alternative. The PSD format is proprietary and access to specs seems restricted.
I found that the OpenRaster format is a pretty good alternative : http://en.wikipedia.org/wiki/OpenRaster
It has open specs and it's really simple. It's a zipped file containing layers as png and a descriptor file. Gimp handles this format quite well and it's easy to export a psd file to an ora file.
You can find some Java tools to manipulate them. It's a part of a more vast project which is still in Alpha : https://code.google.com/p/mediaz/

Hope it'll help people.

弄潮 2024-08-20 15:57:38

我参加聚会迟到了,只是想提一下我已经写了一个 ImageIO GitHub 上提供的 PSD 格式插件

正如其他库提到的,它是只读的,不支持文本或效果图层,但可以通过标准 javax.imageio API 读取光栅化图层和合成图像,这可能对许多人有用。

该插件将读取任何已知版本的 PSD 格式,包括“大文件格式”(又名 PSB)。

I'm late to the party, just want to mention that I've written an ImageIO plugin for the PSD format available at GitHub.

As the other libraries mentioned, it is read-only and does not support text or effect layers, but does read rasterized layers and composite image through the standard javax.imageio API, which may be of use for many.

The plugin will read any known versions of the PSD format, including the "Large file format" (aka PSB).

向日葵 2024-08-20 15:57:38

有一个名为 java-psd-libraray 的项目,用于在 Java 中解析 PSD 文件。

网址:http://code.google.com/p/java-psd-library/

该库不熟悉创建 PSD 文件,它仅供阅读器使用。这样做不可能从 PSD 读取效果,但 github。我不知道它有多好,因为每个版本的 PSD 文件的效果都会改变。

无论如何,这是读取用 Java 编写的 PSD 文件的最佳库。

there is a project called java-psd-libraray for parsing PSD files in Java.

URL: http://code.google.com/p/java-psd-library/

This library is not familiar with creating PSD files it is reader only. There is not possible read effect from PSD with this, but there is extension on github. I don't know how good it is beacuse effects are changed with every version of PSD file.

Anyway this is the best libraray for reading PSD files written in Java.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文