Diffusion Krita 0f19b4cd7fac

Support PSD 1 and 2 channel LayerRecords

Authored by markreid on Jul 6 2017, 7:09 PM.

Description

Support PSD 1 and 2 channel LayerRecords

Summary:
Hi,
This patch fixes some more photoshop file issues I been having. I've been using imagemagick to generate psd files for a while and it rather aggressively tries to reduce the amount of channels it writes. If it detects the layer is grayscale it will only write 1 channel (red) or 2 if it has alpha. This behaviour probably isn't correct but Photoshop is still able to open the files, and the missing channels are just set to white. This patch attempts to replicates what photoshop appears to doing and also fixes some potential segfaults if channelID are set wrong or trying to access out of bounds memory.

Reviewers: Krita, rempt

Reviewed By: Krita, rempt

Subscribers: dkazakov, rempt, woltherav

Tags: Krita

Differential Revision: https://phabricator.kde.org/D6475

Details

Committed
dkazakovJul 6 2017, 7:22 PM
Reviewer
Krita
Differential Revision
D6475: Support PSD 1 and 2 channel LayerRecords
Parents
R37:b0999c9c08b5: rm diff pushed by mistake
Branches
Unknown
Tags
Unknown