As part of business requirement , we need two modes square(360*360) and landscape(400*192) of same image (actual image dimension is 1000*1000) .
We created image presets(wid & hei parameters added) & found that we will get white background appended on the border of image if actual image is landscape & we are trying to retrieve square image & vice versa .
So to remove white background, we applied format alpha-png which helped us in removing transparent background but created another problem of reduced image size.
In order to prevent small size image & white background, we appended scl=1 in image url which cropped the image to desired size & also removed the original content of image.
Is there any solution using which we can get image required size of image without any above mentioned problems.
Low-tech option 1: Only specify one dimension. In your case, you'd specify the width and leave the height blank to let it float. That won't get you the exact dimension you want if the source asset is a different aspect ratio, but without smart cropping, there really aren't good options.
Low-tech option 2: add fit=constrain to the image modifier section. This will instruct Dynamic media to basically do low-tech option #1, but will float either the height or the width depending on which will work better in the specified dimensions.