Reference
| Key |
Default |
|
compress |
0 |
Write new JPEG sizes at jpeg_quality with 4:2:0 chroma (paused while Smush compresses automatically) |
jpeg_quality |
80 |
60–95 |
webp |
0 |
Make WebP copies |
webp_quality |
86 |
30–95 |
avif |
0 |
Make AVIF copies (needs ImageMagick with AVIF) |
avif_quality |
60 |
30–95 |
Options and tables
| Name |
|
{prefix}bb_media_files |
The file index |
{prefix}bb_media_usage |
Where files are used |
bb_media_db_version |
Schema version |
bb_media_backfill, bb_media_usage |
Progress of the index and the usage scan |
bb_media_regen_queue, bb_media_opt_queue |
Attachments waiting for sizes and for copies |
Hooks
| Hook |
Type |
|
bb_media_skip_dirs |
filter |
Top-level uploads folders the unattached scan skips |
bb_media_regenerate_budget |
filter |
Seconds per background size batch (20) |
bb_media_optimize_budget |
filter |
Seconds per background copy batch (20) |
bb_migrate_find_attachment |
filter (BB Migrate) |
Answered by BB Media: an attachment with the same content |
bb_migrate_regenerate |
filter (BB Migrate) |
Answered by BB Media: size regeneration queued |
wp_editor_set_quality, image_save_progressive, wp_image_editors |
filters (WordPress) |
Used for compression |
wp_delete_file |
filter (WordPress) |
Copies are deleted with their files |
Functions
bb_media_lookup( $url_or_path ): see The file index.