It is however possible to do itthis by creating an Action
in the Window > Actions
panel.
Or...or it could be done with a script. Script would give you more freedom to do exactly what you need it to do and more automatically as well.
Before you start reading the rest of the post, I made an action that places image into the selection.
Here'shere's the action in use:
SinceI highly suggest you create the action yourself, as it can be very educating.
However, since the action is super long, I figured I'd share the action file as well.
: Paste Into Selection.atn In hindsight, I should have called it "Place into selection"
Download at your own risk.
...or createInstructions for creating the action yourself:
When you run theThe action and the image is placedstops at some point to the new document,wait for you will have to resizepress enter to apply a transformation. What you need to do is upsize the image a bit to fill the whole document, which is the exact size of (as shown in the selection. This way you fillgif), so that the wholeimage ends up filling the selection.
For example, after step 10
, you might wanna run Image > Canvas size...
, and with the Relative
option checked, add some padding by making and make the document bigger.
This way you would have more slack, when the image is pasted in towould end up slightly bigger than the main document.
You can record new functionsselection, giving you some room to the action withmove it inside the record buttonLayer mask.