Skip to content

Add extraction of layer names and textbox contents to PSDParser#69

Closed
kevindoyle wants to merge 3 commits intoapache:trunkfrom
diffeo:psd-parser
Closed

Add extraction of layer names and textbox contents to PSDParser#69
kevindoyle wants to merge 3 commits intoapache:trunkfrom
diffeo:psd-parser

Conversation

@kevindoyle
Copy link
Copy Markdown

Stepping through the byte stream to find text layer content ran into two blockers:

  • Undocumented 4 bytes Txt coming before the expected TEXT key
  • If the first key consumed is not Txt TEXT, the key which IS consumed must be supported in order to get to the next key. The size of the data each key identifies is not easily determined.

This implementation places the entire block of keyed data into a byte array and scans for the TEXT key.

The dead-end code is commented out, saved for an especially rainy day when we can add support for all the keys and do this properly. (Should I do the right thing and put it on a separate branch?)

References:
PSD File Specification from 2013:
http://www.adobe.com/devnet-apps/photoshop/fileformatashtml/#50577409_pgfId-1031423
Unofficial PSD anatomy lesson from 2014:
https://github.com/layervault/psd.rb/wiki/Anatomy-of-a-PSD-File

@kevindoyle kevindoyle closed this Jan 10, 2016
@kevindoyle
Copy link
Copy Markdown
Author

My apologies for opening this PR. The code is a mess and was meant for testing in our fork.

@kevindoyle kevindoyle changed the title Psd parser Add extraction of layer names and textbox contents to PSDParser Jan 10, 2016
@kujenga kujenga deleted the psd-parser branch January 11, 2016 01:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant