psd: Fix alpha blending
PSD files are saved with as alpha premultiplied. The problem is that alpha refers to white instead of black so it requires transformation formulas. Then, to conver PS premultiplied to QImage premultiplied you have to use the following formula: * V = Alpha + Vps - Max (C, M, Y, K, R, G, B, Gray, L\* components) * V = Vps + (Alpha - Max + 1) / 2 (a\*, b\* components) Where Max is the maximum value depending on the image depth and Vps is the valued read from the file.
Before Width: | Height: | Size: 5.2 KiB After Width: | Height: | Size: 4.9 KiB |
Before Width: | Height: | Size: 983 B After Width: | Height: | Size: 4.0 KiB |
Before Width: | Height: | Size: 94 KiB After Width: | Height: | Size: 93 KiB |
Before Width: | Height: | Size: 191 KiB After Width: | Height: | Size: 189 KiB |
Before Width: | Height: | Size: 115 KiB After Width: | Height: | Size: 114 KiB |