You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|[convert-csv2txt.ps1](scripts/convert-csv2txt.ps1)| Converts a .CSV file to a text file. [Read more »](docs/convert-csv2txt.md)|
233
+
|[convert-images2webp.ps1](scripts/convert-images2webp.ps1)| Converts images in a directory or a single image file to WebP format in parallel. [More »](docs/convert-images2webp.md)|
233
234
|[convert-mysql2csv.ps1](scripts/convert-mysql2csv.ps1)| Converts a MySQL database table to a .CSV file. [More »](docs/convert-mysql2csv.md)|
234
235
|[convert-ps2bat.ps1](scripts/convert-ps2bat.ps1)| Converts a PowerShell script to a Batch script. [More »](docs/convert-ps2bat.md)|
235
236
|[convert-ps2md.ps1](scripts/convert-ps2md.ps1)| Converts the comment-based help of a PowerShell script to Markdown. [More »](docs/convert-ps2md.md)|
This PowerShell script converts images in a directory or a single image file to WebP format in parallel.
4
+
5
+
## Parameters
6
+
7
+
| Parameter | Description |
8
+
| --- | --- |
9
+
|`-InputPath`| The path to the input directory containing images or a single image file. |
10
+
|`-OutputDir`| The path to the directory where the converted WebP files will be saved. It will be created if it doesn't exist. |
11
+
|`-Quality`| The quality setting for the WebP conversion (0-100). Lower values mean smaller files but potentially lower quality. Defaults to 50. |
12
+
|`-Lossless`| Specifies whether to use lossless WebP compression ($true) or lossy compression ($false). Defaults to $true. |
13
+
|`-MaxParallel`| The maximum number of image conversions to run concurrently. Defaults to 10. |
14
+
15
+
## Description
16
+
17
+
The script takes advantage of PowerShell's parallel processing capabilities to efficiently convert multiple image files. It supports various input formats including:
18
+
- jpg/jpeg
19
+
- png
20
+
- gif
21
+
- bmp
22
+
- tiff
23
+
24
+
The converted files are saved in WebP format, which often provides superior compression while maintaining quality.
Converts all supported images in the '.\covers' directory to WebP in '.\covers-webp' using quality 50, lossless compression, running up to 10 conversions simultaneously.
0 commit comments