Pike v8.0 release 1738

Method Image.PSD._decode()


Method _decode

mapping _decode(string|mapping data, mapping|void options)

Description

Decodes a PSD image to a mapping, with at least an 'image' and possibly an 'alpha' object. Data is either a PSD image, or a mapping (as received from __decode)

Parameter options
"background" : array(int)|Image.Color

Sets the background to the given color. Arrays should be in the format ({r,g,b}).

"draw_all_layers" : bool

Draw invisible layers as well.

"draw_guides" : bool

Draw the guides.

"draw_selection" : bool

Mark the selection using an overlay.

"ignore_unknown_layer_modes" : bool

Do not asume 'Normal' for unknown layer modes.

"mark_layers" : bool

Draw an outline around all (drawn) layers.

"mark_layer_names" : Image.Font

Write the name of all layers using the font object,

"mark_active_layer" : bool

Draw an outline around the active layer

Returns
"image" : Image.Image

The image object.

"alpha" : Image.Image

The alpha channel image object.

Note

Throws upon error in data. For more information, see __decode