webmproject / WebPShop

Photoshop plug-in for opening and saving WebP images
https://developers.google.com/speed/webp/docs/webpshop
Apache License 2.0
1.5k stars 125 forks source link

WebP file format plug-in for Photoshop

Current plug-in version: WebPShop 0.4.3

WebPShop is a Photoshop module for opening and saving WebP images, including animations.

Important note: Photoshop 23.2 and newer natively supports WebP. However some features such as preview at encoding and animations are missing. WebPShop can still be installed and used for these use cases and/or for Photoshop 23.1 and below.

Please look at the files LICENSE and CONTRIBUTING in the "docs" folder before using the contents of this repository or contributing.

Installation

Download the binary at https://github.com/webmproject/WebPShop/releases. \ Direct link for Windows x64: https://github.com/webmproject/WebPShop/releases/download/v0.4.3/WebPShop_0_4_3_Win_x64.8bi \ Direct link for MacOS (extract the ZIP archive afterwise): https://github.com/webmproject/WebPShop/releases/download/v0.4.2/WebPShop_0_4_2_Mac_Universal.zip \ Move the plug-in (the .8bi binary for Windows or the .plugin folder for MacOS) to the Photoshop plug-in directory (C:\Program Files\Common Files\Adobe\Plug-Ins\CC for Windows, /Library/Application Support/Adobe/Plug-Ins/CC for Mac). Run Photoshop.

On macOS 10.15+, the prompt "WebPShop.plugin cannot be opened because the developer cannot be verified" can be bypassed by running the following in Terminal (Finder > Applications > Utilities):

sudo xattr -r -d com.apple.quarantine /Library/Application\ Support/Adobe/Plug-Ins/CC/WebPShop.plugin

Features

WebPShop encoding settings - Windows

Photoshop 23.2 and above has partial native WebP support. It will appear as WebP (*.WEBP) in the "Save as type:" drop-down list at encoding. WebPShop will still appear as WebPShop (*.WEBP, *.WEBP). Use the latter. \ WebPShop can also be used at decoding through the "Open as..." menu.

Encoding settings

For information, the quality slider maps the following ranges to their internal WebP counterparts (see SetWebPConfig() in WebPShopEncodeUtils.cpp):

| Quality slider value   -> | 0    ...    97 | 98         99 |    100   |
|---------------------------|----------------|---------------|----------|
| WebP encoding settings -> | Lossy, quality | Near-lossless | Lossless |
|                           | 0    ...   100 | 60         80 |          |

The radio buttons offer several levels of compression effort:

| Label   | WebP speed setting  | Sharp YUV    | WebP "quality" setting |
|         |                     | (lossy only) | (except for lossy)     |
|---------|---------------------|--------------|------------------------|
| Fastest |          1          |      No      |            0           |
| Default |          4          |      No      |           75           |
| Slowest |          6          |      Yes     |          100           |

Animations are supported through a specific layer naming pattern:

All layers must be rasterized, of the same dimensions, and have no filter, mask, group, link, etc. Please see the detailed guidelines.

Limitations

Troubleshooting

If the plug-in is not detected or does not behave as expected, the steps below might help:

If the issue still occurs, check https://github.com/webmproject/WebPShop/issues to see if it is already mentioned or open a new bug report otherwise.

Software architecture

The common folder contains the following:

The win folder contains a Visual Studio solution and project, alongside with WebPShop.rc which is the encoding parameters window layout and About box.

The mac folder contains an XCode project. WebPShopUIDialog_mac.h and .mm describe the UI layout, while WebPShopUI_mac.mm handles the window events.

Build

Current libwebp version: WebP 1.2.2

Use Microsoft Visual Studio (2019 and above) for Windows and XCode for Mac.

[1] By default the XCode project includes and links to the libwebp-[version]-mac-[version] folder in the webpshop directory. The VS project expects libwebp-[version]-windows-x64 (or -arm64).