Is there a way to make an image be blurred on the inside, the same way it is when you -resize it, but still have perfectly sharp edges, the same way it is when you -scale it?
I'm quite sure I should be using masks to do this, but I really don't have any idea how to, so I'm asking you guys.
Examples:
Resized:

Scaled:

(I used -median 10 too on both so they look better)
The image should look smooth as the first one, but have sharp edges and fit on a background that doesn't support transparency just like the second.
Thanks in advance!