What you’re asking for is functionally equivalent to scaling images to fit within a bounding square of each size, so could be achieved with this:
add_image_size('big_xxl', 4500, 4500);
add_image_size('big_xl', 3300, 3300);
add_image_size('big', 2100, 2100);
add_image_size('medium', 1250, 1250);
Consider a landscape image that is 5000×500. These rules will generate images scaled to 4500, 3300, 2100 and 1250 wide.
For a portrait image of 500×5000, these rules will generate images scaled to 4500, 3300, 2100 and 1250 high.
Related Posts:
- How can you set maximum width for original images?
- WordPress Image Editor not working – conflict?
- Image dimensions same as image size
- Best image hosting service
- Filter what image sizes get generated
- Media > Image Sizes aren’t being applied to uploads
- Force WordPress, themes & plugins into using defined sizes
- WordPress Media Image Manager — Creating Lots and Lots of Odd Sized Images
- Large image size stuck on old value, even for new images
- Can I force all uploaded images to be reduced in quality?
- Rotating image does not work for custom image sizes
- Link to resized media file
- Editing image dimension – to edit the main image file
- Force image crop size in media editor
- Set Maximum Width for an uploaded image
- When inserting an image in a post, how to link the image to a resized URL instead of the full image URL?
- How do I get WordPress to create resizes of a supplied default image in a theme?
- TwentySeventeen $content_width not updated in admin
- How to resize image in wordpress from backend? Seems like bug in wordpress
- Only current gallery images with get_attached_media
- Custom image sizes
- Set default image link target in Gutenberg image block
- Custom post type with a forced fixed aspect ratio image crop
- How do I force WordPress to show most recent version of images in the media library?
- Removing default image size list in Media Box
- How to capture the selection:toggle event fired by wp.media
- wp media regenerate unknown –image_size parameter
- Is there a plugin to make attaching images easier?
- How to display all images “Uploaded By” an author
- Shortlink directly to a media file?
- Is it possible to generate JPEG progressive thumbnails?
- Way to display media library in frontend
- Images are registered in media library but still won’t show up
- Add visual editor to Media Edit Screen
- Rest API rename media
- Disable drag and upload in Media Library
- Custom media picker in meta box: how to select available image sizes?
- Upload images from custom plugin using the media modal
- Add media column to edit post screen
- How to stop unlink images when remove a site or user
- Add custom tab on the media manager
- Thumbnails are bigger in size than the original image
- Link to full size image or attachment page in photo theme
- Front end wp_editor not rendering audio/video links
- How to get media objects
- uploading images to specified directories
- Handling image uploads without thickbox
- How to hide some specific attachments using post meta from media library
- How to change image atributes right before an image to be saved?
- Is it possible to change ‘Link to’ in all images in all articles?
- Importing Media IDs but not related attachment
- How to upload WordPress Images to remote web server and display those images in WordPress gallery [closed]
- What is the alternative to “ when it comes to calling Media (image) files in the ‘attachment.php’ file?
- How to open a Media Uploader dialog with a particular image is selected
- Images uploaded to the media library has strange colors. However, in the edit screen the color is ok
- Blank upload.php page
- media library not showing thumbnails after deleting full image
- Retrieving Meta from Image Attachment
- Media attachment pages giving 404’s
- Extending wp.media.model, query media from different blog on network and refresh view
- Is it possible to change image size used for preview thumnail in Add Media popup
- WordPress automatically adds links to uploaded images
- In creating a theme, how can i allow a user to change an image outside post/page content?
- Why WordPress suddenly changed sizes of thumbnails?
- Theme loosing some images when moving to new server
- Auto delete pictures in media library by age
- WordPress creating images if uploaded image is greater than 960px on one side?
- How to get all inline images in post content? [duplicate]
- Convert all uploaded PNG files to PNG-8 format
- formatting horizontal and vertical images in Settings?
- Get all media from wp-json/wp/v2/media
- Access generated thumbnails
- how can I change all wordpress media file url to custom cdn url?
- Profile image does not upload
- unable to write to the database while uploading images
- How to display the Media Library Items Upload date
- Media Library modal customization
- Get all uploaded images using REST api
- IPTC and custom thumb size
- WordPress REST API to get all media not working
- Images not loading on webpage, and links to other media give 404 Not Found
- unsharp thumbnails after uploading image
- Append Media/Attachment IDs to Gallery Shortcode HTML Output
- Post images are not displayed in media library
- MP4 file links download instead of playing
- Media and all images disappeared from my wordpress site
- Replace Swedish characters in filenames
- Get the Playlist embedded in Post/Page content
- Can we reuse WordPress drag drop media upload in plugins?
- How can I change the default image behavior?
- Import media in bulk with caption and titles?
- wp media popup close all popup
- How do I display image files as links?
- Broken Media Library
- Unable to send upload url
- Is it possible to convert various image types from remote URLs to WebP and then serve them immediately?
- How to import and update images/galleries that point to an old site
- Media Library empty after server migration
- How to import external media items into wordpress media library (without using storage)
- Add custom css class to wp-list-table row for Media Screen