Giter Club home page Giter Club logo

psdump's Introduction

Introduction

psdump is a command line utility which parses Photoshop files and outputs their layer hierarchy as a text, JSON, or XML data. Position and size of each layer are included in the output.

The program has been tested on the following systems:

  • Mac OS X
  • Windows XP, 7
  • Linux (Ubuntu 9.10)

Known issues

When used on Mac OS X with a Photoshop file slightly larger than the most basic one, psdump crashes with Segmentation fault. The reason of the crash is supposedly a bug in the libpsd. Further investigation is planned for an unknown moment in the indefinite future.

Installing psdump

In order to start using psdump you will likely need to build it from source. However, there are precompiled binaries for Mac OS X and Windows family. They can be found on the Downloads page.

Once you've downloaded a binary release for your OS, unzip it and type psdump --help in the terminal window.

Building from source

The UNIX way

Building from source is fairly simple on a UNIX-like system. You just need to run make in the terminal window. The binary will appear in a newly created 'build' directory. (If you are running some kind of minimalistic Linux distribution, you may need to additionally install g++.)

You can also run make test to run the test-suite and make tidyup to remove intermediate object files. (If you don't have python installed, run make shtest instead of make test.)

Instructions for Windows users

To build from source on Windows there are several options.

The first one is to use MinGW with MSYS. With those tools installed, building is as easy as typing mingw32-make (or a similar command) in the MSYS terminal window.

Another way to build psdump is using Cygwin. With 'g++' and 'make' packages installed, you just need to run make in the Cygwin-bash.

Important notice. If you build psdump using Cygwin, it won't work without cygwin1.dll.

Lastly, a Microsoft compiler can be used to build from source. You will find a Visual Studio project file in the 'vcproj' directory. This file has been created in MS Visual Studio 2005 (version 9).

Dependencies

To parse Photoshop files, libpsd is used. You don't need to download it separately since its source code is already included with psdump and it hasn't changed since, I guess, 2007. You may visit its project page on SourceForge.net.

Apart from libpsd, there are no other requirements to be able to successfully build psdump from source.

Roadmap

Feedback, feature requests, and code reviews are most welcome! Please let me know about your experience using psdump.

It has been designed in such a way that makes it easy to add more output formats and even to parse other hierarchical files, not just Photoshop ones.

The following improvements are expected to be introduced in the future:

  • provide more detailed documentation on adding new features
  • check for conformance of JSON and XML outputs to their corresponding specifications
  • tweak the program architecture to make it easy to handle multiple document outputs into a single file in a polymorphic way
  • write unit-tests and create a more elaborate test-suite
  • build and test on as many platforms as possible (your help will be appreciated)

Once the above features are implemented, version 1.0 will be released.

psdump's People

Contributors

alco avatar

Watchers

James Cloos avatar fly avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.