What's new
Photoshop Gurus Forum

Welcome to Photoshop Gurus forum. Register a free account today to become a member! It's completely free. Once signed in, you'll enjoy an ad-free experience and be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Auto scale and align 2 layers.


crash222

New Member
Messages
2
Likes
0
Hey everyone, thanks in advance for reading and trying to help. I'm trying to automate a long, tedious process that I do a lot, and have it all except this one step:

I need to overlay 2 images that are always similar in shape, but not at all in content. When pasting the new layer, how can I get it to adjust the scale and rotation automatically?
The images that I need to overlay are limited (it's the same few pics that I'm constantly importing and overlaying), so it would be good if I could - let's say - program a 3 or 4 point 'frame' on the images I use often, then, when I load the other one, quickly set up the same 'frame' on the other image, and then let the process run, matching the frame on each image.

If that's still not clear, I'm face swapping a comic book for my nephew - replacing the main character's face with his. So, on each frame I'm checking the angle of the characters face, picking a picture of my nephew at the same angle, and swapping them. So, I've got it all decently well automated, but constantly have to adjust scale and rotation of the face after I import it.

Thanks again!
Looking forward to a solution!
 

MrToM

Guru
Messages
3,595
Likes
3,321
Not sure if this can be done 'exactly' as you request but without having some sample images to work with and an example of the final result its difficult to suggest anything really.

Having your 'importing' images as a 'smart object' may work....it will scale and rotate images although it will be the same scale and rotation each time....but that does mean that its done most of the heavy lifting....you'd spend less time tweaking each image to how you require.

If you have some sample images to try it would help enormously.

Regards.
MrToM.
 

crash222

New Member
Messages
2
Likes
0
Here's the cover from the first one. They don't need to be phenomenally convincing. We just figure this will encourage him to read, which is why I'm trying to automate the process as much as possible.
,View attachment yugioh1 cover.pdfyugioh1 cover.jpgyugioh1 cover.jpg


Think of it this way, let's say I had 2 perfect squares, each with completely different color and pattern content fills, is there any way (even if it's convoluted long way around) to get them to align automatically for size and rotation?

Thanks

And just FYI - I've already taken care of the 'heavy lifting' in that sense. Right now the method that I'm using has used Robotask along with photoshop to automate the following process (just part of the overall process I have now):
- I manually select the face in the comic using the quick select wand then automation starts:
1 - bring selection into a new file (which is only as big as the selection)
2 - From that, automatically find the width of the image, then close it.
3 - Paste real photo face in, and free-transform with locked aspect ratio, inputting the width extracted before.

That was the best way I could conceive of how to make sure the real photo ended up as close to the right size as possible.
That's why, the last step to have it practically entirely automatic, would be to align the new layer with the face of the old layer.
 
Last edited:

MrToM

Guru
Messages
3,595
Likes
3,321
... is there any way....to get them to align automatically for size and rotation?...
Yes...use a smart object.

Set up a document into which you place your images.
Save that document somewhere sensible.

In another document use 'Place Linked' to place that document into your final PSD file.
It will be 'placed' as a 'Smart Object' and ready to transform so you just need to rotate and / or scale or whatever you want to do to it.

Now when you edit the first document and save it the 'linked' layer will auto update....scaling and / or rotating to fit.

Think of it as making a window, (in one PSD file), but changing the view, (in a totally different PSD file).

The other benefit of a Smart Object is that should you need to you can always transform again without fear of degradation.

Regards.
MrToM.
 

Top