• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

PS - automatically resize mock up photo frame based on the smart-object artwork size

Community Beginner ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

I've seen picture frame mockups where the artwork is placed in a smart-layer and, regardless of the image aspect ratio and resolution, the mockup frame resizes perfectly. This is without using automated actions.

 

I've created a mock-up that applies fx to the photo for a drop-shadow float-mount effect. Then a second layer for the mockup frame. Great.

 

On to the tricky bit.... I created a smart-object into which the photo was inserted  and drop-shadows applied to (note: the smart-object is just out of sight above the other 2, and the original one was of course hidden)

 

How can I have the Mount & Frame Layer respond to the aspect ratio and size of the smart-object? It needs to be as simple as possible for others to drop the photo into the smart-object, save, et voila! I'll then add various options for wall backgrounds etc.

 

I've thought of various options but my PS knowledge is very limited. I can only think of using free transform but it's far from ideal.

 

How would you achieve this?

 

PSFraming1c.png

Views

10.0K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Jul 09, 2020 Jul 09, 2020

I think what you are seeing is the weird way Photoshop handles images with transparent boarders.  I went to their site and they have a demo.  The demo PSD of course does not work like you show in your video.   The PSD is not structured like the PSD in you video particularly the smart object.    Looking at what I could of the PSD structure in you video and how you Edited the Object.   It look like they are taking advantage of an odd Photoshop behavior.   Photoshop more or less trims off  transpar

...

Votes

Translate

Translate
Adobe
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

Smart Object Contents have to be replaced with content the same size.  If you want to replace a smart object layer's image with any image file the may have any size you would need to open the smart object and paste in the and resize the image to fill the smart object canvas. If the Imags'g Aspect ratio does not match the Smart Object Aspect ratio there will be some content lost.  If you fit the Image to the smart object canvas there will be borders no image content loss.  My BatchMockupTemplates.jsx  scripts default is to use replace content to replace images but it has edit options to replace images other ways into mockup templates.

image.png

 

 

You can create template without any smart object layers in fact templates do not even need to have images in them. Here is a video of a template being populated with a script. The template has a Background layers and and overlay layer with its fill set to 0 all that is visible is the layer style generated for the layer content.  The only other content in the template are 5 Alpha channels that Map the location sizes and shape of the 5 images that will be placed in by the script.

image.png

Capture.jpg

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

You could any other type of I believe there is one call something like Frameshop.  It frames your image rather than placing your image into a frame.  The frame is built around your image. Your Image  remains untouched.   I have recorded Actions in the past to frame images. It not hard to build frames.  Photoshop has many tools and you can automate some processing and can assists some processing  with interactive actions and scripts.  Examples 

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

Thanks for the ideas JJ. The Smart Object behaviour you mention has been exactly my experience of it - the canvas size has to be the same size as the content. 

 

I've seen a photoshop mockup that seems to get around this problem but I don't knowhow.

Here are the layers - which shows an artwork smart object but somehow the mount and frame layers show the same thumbnail and double-clicking any of the thumbnails open the same smart object.

FrameSmartObject.png

 

And here's once you open the smart object - nothing special that I can see.

 

InkedSmartObjectLayers.jpg

 

Is there anything I can look into to understand how this is working? I bought licensing for this mockup but I don't think the licensing allows alterations - so it's a case of figuring it out so I can create my own mock-up generator for my use 🙂

 

Could there be a script running in the background? I don't know how scripts work in PS.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

A simple template for your frame.  Replacement images should have a wide panorama landscape aspect ratio to work well.   Narrow images will lose too much content resizes to fill the aspect ratio image.

image.png

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

Thanks again for taking time to answer so thoroughly. I get what you're saying with using an image that has a similar or identical aspect ratio to the frame mock-up. However.... the 3rd party licensed mockup template changes the mount and frame to match the smartobject aspect ratio. I've tried many aspect ratios and it fits perfectly without cropping or distorting. I've I give it a square image, it gives me a square frame. If I give it a 3:1 pano, it gives me a 3:1 frame.

 

I'm a landscape photographer and I've opted to shoot in whichever format best suits the scene in front of me. It could be a 16:9 3:2 3:1 4:3 1:1. Resizing isn't an issue as I can export from Lightroom with the long-edge set to x pixels. The many different aspect ratios are a problem though. 

 

I'm tempted to create actions for the different aspect ratios, or use the approach I'm currently using but with a Smart Object, mount and frame layers for each aspect ratio. Backgrounds etc can then be common to all aspect ratio sets.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

I wrote that you can frame an image that  its not hard to build/make frames. That is a very different process then placing images into a template.  You build a frame about the placed in and sized image.   Its not a template the frame has to be built for the image at hand.  You construct the fame. And still images have to be within some resaonable aspect ratio ranges. If you want to create a constant document size.  How would frame be constructed for images that have outrageous aspect ratios in a desired size canvas for supper wide or supper tall aspect ratios  images  10000:1 or  1:1000000

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

Ok, possibly I'm using the wrong language semantically - re template.  If I understand correctly, you're saying the PSD I've been referring to isn't a template as such, but that it generates a frame around the image?  and it does so regardless of the aspect ratio that I use - as tried and tested (as below placed the image within the smart object, saved, and that's all). I can't comment about any outrageous ratio's - I'd imagine there's a point where it stops working very quickly.

 

Based on everything you've said and this PSD that frames perfectly regardless of aspect ratio - how would that be done?

 

example3b.pngexample1a.pngexample2a.png

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

How do you populate your image into that psd.  What Photoshop functions do you use?  What are the steps you perform? The PSD is not building the frame.

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 09, 2020 Jul 09, 2020

Copy link to clipboard

Copied

It's exactly as I've said - open the smart object place any aspect ratio image at a resolution of your liking, save, and there it is. Here's a video showing it with a couple of different images...  https://drive.google.com/file/d/12rFDBjPR-mKKluyW62PCXur9kqOSHyAR/view?usp=sharing 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 09, 2020 Jul 09, 2020

Copy link to clipboard

Copied

I think what you are seeing is the weird way Photoshop handles images with transparent boarders.  I went to their site and they have a demo.  The demo PSD of course does not work like you show in your video.   The PSD is not structured like the PSD in you video particularly the smart object.    Looking at what I could of the PSD structure in you video and how you Edited the Object.   It look like they are taking advantage of an odd Photoshop behavior.   Photoshop more or less trims off  transparent] image boarders during Place and Copy Paste   The resulting  layer bounds is that of the image pixels bounds not the filse canvas size that can be a problem if you  counting of the transparent boarder to position the image on the document composite image.   It also created the wrong size object for smart object layer object transform are recorded for the original object size.  Perhaps they figured out to set the Smarts object layers transform to position the object at 100% width and 100% height onto the document canvas.  To me the frames you see  PSD are Layer Styles nothing more. All the Frame layer are copies of the  ARTWORK smart object layer the name of the layers have been changed to Frame Type Names and have a frame layer style added.  The all share the same object.  The Frames  you see are nothing more than layer styles on the ARTWWORK Smart Object layer and the Frame Smart Object layers Mount the Smart object layers that have the share object that you make visible. The PSB object has a Large mostly  transparent canvas.  Their demo psd has a jpeg object that does not support  transparency and if you edit it you can add layers and save because would turn into a save as because of  the layers.  Save will only work when the is only layer if the document was opened from a jpg.  If you make the image you use not a rectangle  the frame should follow suit and not be a rectangle.

Capture.jpg

So there are no frame pixels Photoshop generated pixels for layer effects.....

Capture.jpg

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 10, 2020 Jul 10, 2020

Copy link to clipboard

Copied

You've unravelled the mystery! Thanks JJ

It all makes sense with the transparent pixels being ignored and the framing just being fx to create a frame effect. I need to look into the actual frame options in PS - like the examples in your last message.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 19, 2020 Jul 19, 2020

Copy link to clipboard

Copied

LATEST

I do not like the new Frame tool in Photoshop at all. It has issues, it uses places that has issues, If messes the look of the Layers palette.   I have been framing image vial Photoshop scripts since CS2 where I was beat up by Place and its implementation. Photoshop has never had a problem framing images there no reason for an additional kind of mask.  These frame mask will not change any frame you have in a document it a mask on the smart object layer and I doe not know what would happen if you changes the size of its placed smart object. In general is a bad idea to change the size of a smart object via Replace content or editing the object and changing it canvas size.

 

I removed the Frame Tool from my Tool Bar and disabled its shortcut.

 

If you want a fancy frame that dynamically changes with images size you need to build the frame dynamically via Photoshop automation action or script.

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

You can create a mockup template for your frame using a smart object layer. However there is no need to for your image is not distorted to have some perspective view. Your image is a straight on view.  My batch mockup scripts would have no problem populating the templates smart object layer. Still replacement images should have a wide landscape panorama aspect ratio to work well with your panorama frame.   If you create and photoshop script or action that uses content aware resize it may create acceptable results for some images. Content aware resize will not resize someone's narrow portrait into and acceptable image unless they are going for that house of mirrors effect.

 

A simple Smart Object Layer template coulf be as simple as this.

image.png

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

Simple put if the Image need to resize the resize need to be a constrained resize else the image will distort.  If the images aspect ration has to be changes something has to give.  Content Aware Scale will not do a good job in many cases it is not a good general resizing default...

 

Here is a 2:3 Image Content Aware Scaled to 3:2  what do you think to 16:9 would look like.

image.png

 

 

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 08, 2020 Jul 08, 2020

Copy link to clipboard

Copied

My Batch mockup populating scripts have three resizing options replacing smart object layers content.    Content Aware Scale is not one of them.

image.png

Replacement image need to have Aspect Ratios that are close to the templates image's aspect ratio for good results.  

JJMack

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines