Skip to main content
StrongBeaver
Legend
April 16, 2011
Answered

The agony of flattening layers with blend modes

  • April 16, 2011
  • 13 replies
  • 91526 views

I need to flatten a series of layers within a group, which have different blend modes.  I've tried merging group, that resorts all layers to 'normal mode', I have also tried merge visible which does the same as 'merging group', convert to smart object, same results.  I don't want to go the route of flatten image, it has worked to a degree, my photoshop file is organized how I want it and I want to strictly take the group or select those layers and merge them while keeping the blend mode in tact.


've searched for answers and none of the answers were anything I haven't tried.  Is there not a script, filter that can solve this dilemma it's quite common as you may or may not be aware of.

    This topic has been closed for replies.
    Correct answer D Fosse

    View at 100% and try again!

     

    The blend modes are preserved. What you see is something else.

     

    Adjustment and blending previews are calculated based on the on-screen image for performance reasons. Zoomed out, that means a scaled and softened version. With all these noise effects, that means a lot of intermediate values that aren't there in the full data.

     

    To be absolutely clear - the final result is correct. The preview is misleading because you don't see it at 100%.

     

    100% is a very significant number. It means one image pixel is represented by exactly one screen pixel. This is the only true representation of the actual pixel structure.

    13 replies

    Participant
    July 3, 2022

    I'm having this problem too. I have groups of layers and want to merge some layers together to reduce complexity and edit differently.

    One layer is set to blend mode COLOR

    When I merge with the layer below it which has normal blend mode, it loses the look and becomes something entirely different, not what I want. 

     

    Someone gave a solution to use SHIFT+OPTION+COMMAND+E (for mac) and that will make a copy merge, but it merged my entire document and made it a new layer, rather than just those layers I had selected. So I'm still not totally sure how to do this properly. 

     

    Hope Photoshop can make a good solution to this issue.

    Zesty_wanderlust15A7
    Known Participant
    July 3, 2022

    That Copy Merged looks at the visible layers (what you see), not selected ones.

    You could make a Layer Comp to save your current state, then see if you can get there having just enough of those few layers visible and Copy Merge those.
    When I have these kinds of Merging problems, it's usually because there are Blend Ifs, which I can somewhat understand  -- otherwise not that often.

    Participating Frequently
    February 24, 2022

    I have the same problem. I have multiple layers and folders with various blend modes applied to them. I want to be able to save the final image (screenshot) as I see it on my screen, but when I merge all the layers (Ctrl +Alt + Shift + E), the image loses the effects because the layers don't apply their respective blend modes. I know the reson why, but isn't there a way to save the funal image and retain the visual effects prior to merging the layers?

    Marty Geller
    D Fosse
    Community Expert
    D FosseCommunity ExpertCorrect answer
    Community Expert
    February 24, 2022

    View at 100% and try again!

     

    The blend modes are preserved. What you see is something else.

     

    Adjustment and blending previews are calculated based on the on-screen image for performance reasons. Zoomed out, that means a scaled and softened version. With all these noise effects, that means a lot of intermediate values that aren't there in the full data.

     

    To be absolutely clear - the final result is correct. The preview is misleading because you don't see it at 100%.

     

    100% is a very significant number. It means one image pixel is represented by exactly one screen pixel. This is the only true representation of the actual pixel structure.

    imperialprogram
    Participant
    September 2, 2020

    I think I figured out why the blend modes don't show after merging group, did an experiment with 2 files, 1 file with the mode of "pass through" and another with the mode of "normal" the Layers in each file have the same stuff (layers and with different blend modes). The File with "normal" blend mode shows different result than the File with "pass through" blend mode. When merging the file with "pass through" blend mode will show different result from what you see before merging, while the "normal" blend mode file will merge and show the same result you see before merging. So I'm thinking it's better to set File/Folder mode to "normal" first before working on the project, hope this helps.

    Participant
    May 14, 2011

    StrongBeaver.

    All I can say is that at least I UNDERSTAND your problem. I have just encountered it myself.

    You are one of the few people who has actually worded it properly, and STILL you received patronising and completely misunderstanding replies.

    I am using Photoshop Elements 4.0 on a mac and when I merge layers with blending, the visual effect of the blending is lost. This is completely ridiculous: Layer blendings have no purpose if you cannot flatten the image while keeping the VISUAL EFFECT of a blending mode (NOT the blending mode itself, as some people have misinterpreted). You need to flatten an image to do almost anything with a photoshop document.

    In older versions of photoshop, this was not an issue - flattening an image reproduced EXACTLY what appeared on screen.

    If there is no solution to this very real problem, then Layer Blending is COMPLETELY useless, and only for show. This is a very serious problem with the program and I am surprised that it hasn't been brought up more often.

    I apologise if someone did post a solution that works.

    Christian_Davideck
    Known Participant
    May 14, 2011

    post .psd file, JanusII

    (reduce image resolution if file size too big)

    Participant
    May 14, 2011

    Christian Davideck, thank you.

    That was simply the solution!

    Because my file was a very high resolution, the preview of the layer blending in the unflattened image looked radically different to the rendered version of the blending when flattened.

    Hence, when I lowered the resolution, the unflattened preview and the flattened final looked almost identical.

    Similarly, in the original file, if I zoomed in, the unflattened and flattened versions looked identical.

    I take back all the bad things I said about Photoshop. Sure inaccuracy of previews while editing are annoying, especially the change in appearance at different zoom levels, but the flaw is nowhere near as heinous as I imagined.

    I am not sure if this is a solution to StrongBeaver's original problem, but it might help...

    Participant
    April 24, 2011

    Hey,

    I havent read all the replies so I might be repeating something, but, this is how I get aorund it...

    1) Put everything above your group into a new Parent Group. (create a folder at the top, select all layers above your group and move them into it)

    2) Put everything below your group into a new Parent Group. (create a folder at the bottom, select all layers below your group and move them into it)

    **You should now have 3 groups - the one you wanna merge, one above it and one below. (and maybe a pesky background layer outside of groups)

    3) Turn visibility off on the Parent groups. (and any pesky background layers)

    4) Inside the group you wanna merge, create a new layer at the top.

    5) With new layer selected hold ALT then click the Floating Layer Windows sub-menu/drop down thing (just below the close icon) and click megre visible.

    6) That should megre the goods to one layer and retain your effects.

    7)..up to you...but i usually push all the stuff below that new layer into a subgroup and name it "source".

    Hope that helped.

    Rob

    Christian_Davideck
    Known Participant
    April 28, 2011

    by all means, don't post your PSD file, StrongBeaver!

    Participant
    April 18, 2011

    Oh, the agony of defeat!

               

    StrongBeaver
    Legend
    April 18, 2011

    Obviously merged layers become one layer and you can't have more than one blending mode per layer. So, if I understand you correctly, when you say: you want to keep the blending mode intact, you apparently mean to keep the same appearance after the layers are merged. Well, this is impossible if the bottom layer from the group is not fully opaque where the other layers have semi-transparent pixels.

    If you flatten everything with fully opaque white layer at the bottom, the appearance will be preserved. In fact you should never create images without a fully opaque layer at the bottom.

    How can you keep the semi-transparent pixels in tact, upon merging the group ? I applied a fully opaque layer at the bottom of the group and the semi-transparent pixels (blend modes) were not preserved.

    I am sorry if you feel I have in any way been condescending. That was not my goal or intension.

    I too have been made to feel that way on this forum at times by some of the better known posters.

    I am trying to look at your question with new eye.

    That is why you, and others should re-read what they write. Unless you want to come off as agressive, condescending etc you may notice what you wrote does not sound what your intention is.

    Are you saying that when you flatten or merge a series of layers, whether in a predefined group or individual, that have different blend modes that those blend mode adjustments, the way the image looks, are not being retained in the final merged or flattened image and the image looks different?

    Read read my post and post #17, all of which target the problem head on.

    Inspiring
    April 23, 2011

    StrongBeaver, you have posted a PSD file with 3 layers in a group, one of which is fully transparent and does absolutely nothing.  The other two are using two different blending modes, "Normal", and "Color Burn".

    First, as has been stated a number of times there is NO WAY this can be flattened into one layer and do all the exact same things it does as a stack of layers with different blending modes.  A single layer can blend in only one way, so BY DEFINITION some of the blending modes must be lost when you reduce the number of layers to 1That's the way it works, whether you like it or not!

    The third layer in the group which was fully transparent was following Emil steps and for him to take a look at the file.  If you read what Emil posted in message #29 you'll see he had a transparent layer.  Noel you say that a single layer can blend in only way one, how come Emil to a extent has done it in post #29 I can't say he has completely succeeded because I didn't complete the steps on my composite but it is in the right direction from what I did follow though.

    Second, the rightmost part of your _NIK0164 layer, with Color Burn blending shows up as fully opaque on top of background transparency because it simply doesn't make any sense to try to Color Burn a fully transparent pixel (i.e., nothing at all), so we can only guess that the person programming the Color Burn blending code at Adobe tried to make it do something useful in that case. However, the same "keep these pixels showing" decision simply cannot be taken when you show the layer against a real, opaque background.  Color Burning White, in your example, always yields White.  That's just the way it works!

    Given that with merging the Color Burn blending mode WILL be lost (see the first item above):

    A.  If you Color Burn over a transparent area you get a copy of the pixels in the Color Burn layer.

    B.  If you Color Burn a White background you get...  White.

    There are two things you can do:

    1. Layer - Merge Group, which preserves the transparency in the fully transparent parts, and shows you the Color Burn layer pixels to the right, just as you see when the layers are displayed over a transparent background.

    2.  Layer - Flatten, which shows you what would happen when you try to Color Burn white pixels (i.e., they stay white).

    What you see is what you get.

    Since neither merging the group or flattening the image is giving you the result you want, clearly you expect different behavior than what Photoshop is programmed to deliver.  Have you ever heard the phrase "You can't get there from here!"?

    So DEFINE WHAT YOU'RE TRYING TO ACCOMPLISH INSTEAD OF GETTING BOGGED DOWN IN THE DETAILS OF HOW YOU'RE DOING IT WRONG!  There's most likely another way to get there than the way you've set this up.

    The _NIK0164 layer is not top of a background transparency layer it's ontop of layer 1, look again.

    Look at the composition again, really look at it instead of going off on a tangent how I don't understand Photoshop.  It is such a simple thing yet I'm reading paragraphs of text that is turning a mountain out of a molehill.  The composition has _NIK0164 ontop of Layer one, the right side of the composition is white, why is it white ? It's white because the blend mode for _NIK0164 is 'color burn' change blend mode from 'color burn' to 'normal' and layer1 has no more semi-transparent pixels, correct ?!?!?!?

    Merge the layer group, what are the results ? The results are that the _NIK0164 layer is no longer semi-transparent, flattening the image successfully does the task yet why is my sample-composition in a group ?!?!?! Is their a reason for this ?!?!?! Yes there is, my original composition has a specific group with layers I want to merge while keeping their original blend modes and while leaving all other layers and groups UNMERGED.

    I'm not the one bogging down the thread with details, I explained it over the course of atleast three posts like I said in one post a game of pictionary seems to be the only likely way this will get solved, or for Noel to understand.

    Emil, could you post your results using the sample composition and what I had just wrote in this thread.


    StrongBeaver wrote:

    ...

    Emil, could you post your results using the sample composition and what I had just wrote in this thread.

    No, problem but I got somehow confused by the fact that you confirmed that what MTSTUNER demonstrated is the final result you want from the file posted. If that wasn't the case, I would assume that the final result, as explained originally, is to flatten the Group 1 copy (Ctrl + E when the group is selected) and this should not change the appearance and also will preserve the fully transparent pixels of the group. Currently when you select the group and press Ctrl + E this changes the image by showing the additional strip to the right of the intersections from the two layers in the group.

    If you want to apply my instructions from post #29 on the file you posted, first here are the steps I already posted:

    Make sure you have a fully opaque white layer (not background) at the bottom of all layers. In some cases this is not needed but it doesn't hurt to have it and it ensures the expected result.

    Hide all layers except the layers in the group to be merged. If you have a complex hierarchy of layers with different visibility, use Layer Comps to save a layer visibility stage.

    With a layer in the merging group selected, take the Magic Wand tool making sure the Tolerance is 0, Contiguous is unchecked, Sample All Layers is checked, and click on a fully transparent pixel to select all fully transparent pixels in the merging group.

    Show the previously hidden layers and in the Layers panel select all layers under the merging group.

    Right click in the Layers panel and choose Duplicate, alternatively hold Alt and drag them under the merging group.

    Add the layers from the merging group to the selection of duplicated layers (Shift + clicking the top layer of the merging group makes this easy)

    Right click in the Layers panel and choose Merge Layers (Ctrl + E)

    Press the Delete key to delete the pixels that were fully transparent in the merging group

    And here's how you should apply them to your file:

    • Doubleclick the Background and press OK to make it a layer.
    • Hide Layer 2 and Layer 0
    • Select (highlight) _NIK0164 layer in the Layers palette, take the Magic Wand tool making sure the Tolerance is 0, Contiguous is unchecked, Sample All Layers is checked, and click on a fully transparent pixel to select all fully transparent pixels in the merging group. In your file you have fully transparent pixels at the top left and bottom of the image. Turn on the transparency grid in the preferences if is is not already, to see these transparent pixels.
    • Show Layer 2 and Layer 0, and select Layer 0.
    • Right click in the Layers panel, choose Duplicate Layer and pres OK, alternatively hold Alt and drag Layer 0 under the merging group.
    • Add the layers from the merging group to the selection of the duplicated "Layer 0 copy" (With Layer 0 copy selected, Shift + clicking on "Group 1 copy" merging group makes this easy)
    • Right click in the Layers panel and choose Merge Layers (Ctrl + E)
    • Press the Delete key to delete the pixels that were fully transparent in the merging group

    That's it now you have merged the group without altering the appearance and the fully transparent pixels in the merging group remain after the merging which with your file become more obvious if you hide Layer 0 and have the transparency grid on.

    The file you posted is not very good example of the solution I suggested. Also Layer 2 doesn't make any difference but for the purpose of this exercise let's assume there could be something on it. If you want to see more obvious example, instead of the white Background in your file use something more complicated like a image build with multiple layers having common fully transparent pixels or at least a photo image instead of the white background.

    Inspiring
    April 18, 2011

    StrongBeaver wrote:

    I need to flatten a series of layers within a group, which have different blend modes.  I've tried merging group, that resorts all layers to 'normal mode', I have also tried merge visible which does the same as 'merging group', convert to smart object, same results.  I don't want to go the route of flatten image, it has worked to a degree, my photoshop file is organized how I want it and I want to strictly take the group or select those layers and merge them while keeping the blend mode in tact....

    Obviously merged layers become one layer and you can't have more than one blending mode per layer. So, if I understand you correctly, when you say: you want to keep the blending mode intact, you apparently mean to keep the same appearance after the layers are merged. Well, this is impossible if the bottom layer from the group is not fully opaque where the other layers have semi-transparent pixels.

    If you flatten everything with fully opaque white layer at the bottom, the appearance will be preserved. In fact you should never create images without a fully opaque layer at the bottom.

    StrongBeaver wrote:

    Where did I ever say, that I didn't understand !?!?!?! It is clearly visible, technicalities aside that when the layers are merged that the composition resorts to 'normal' mode.

    Well that's the default because it has to be some mode when you have layers with different modes. If all layers were with the same mode, it will remain after merging. If you don't like the default normal mode, change it  to whatever mode you want, but as I said, if you have semitransparent pixels this will not help and still change the appearance. Your problem is the semitransparent pixels, not the mode.

    Participant
    February 15, 2024

    emil thank you soo you resolved my problems i had... and yes problem is the semitransparent pixels on my  EXR shadows that was causing me problems at the moment i was merging 

    April 18, 2011

    what I do not understand is why the original poster, Strongbeaver, can not accept that no matter how many layer you have, in groups or individually, with different blend modes on those layers, in groups and individually, when you flatten or merge those layers they can no longer retain the different blend modes. They are all combined into one flatten or merged layer. They are no long individual layers.

    Yes the blend mode adjustments for each layer is carried over into, applied to, the final image. But that final flatten or merged image must now have a Normal blend mode. It is now one (1) Layer and you can not have multiple blend modes in one layer.

    Noel Carboni
    Legend
    April 16, 2011

    It occurs to me no one's asked you why you want to merge the layers...  Is the performance bad or something?

    Don't I recall that with a group you collapse the whole thing so it doesn't take up a lot of room in your Layers panel?

    -Noel

    Christian_Davideck
    Known Participant
    April 17, 2011

    Noel Carboni wrote:

    ... why  merge ... ?    


    There are lots of reasons.


    (1) if you don't need the separate layers anymore, it helps reduce the document structure's complexity

    (2) reduced file size

    (3) you can apply a clipping mask to the merged layer (but not to a group)

    (4) better performance

    (5) you can retouch the merged layer differently

    (6) you have different possibilities for knockout

    (7) [...] etc.

    Noel Carboni
    Legend
    April 17, 2011

    Thanks.  Believe me I know all the reasons why *I* might want to merge, but I'm curious why it's important to StrongBeaver.

    I tend to keep my compositions as merged as possible, actually.

    Since it's not really working out for him, though, I was just wondering why it was so important to do so.  Just idle curiosity.  Maybe he's trying to work around a problem that can be solved another way.

    -Noel

    April 16, 2011

    Fact is you can not merge or flatten a group of layers and have the individual layer blend modes stay. Once merged or flattened they no longer individual layers. They have an effect on the individual layers and that effect from each individual layer will be carried over into a merged or flatten layer but that new merged or flatten layer will then have a Normal blend mode. It has to, it can't have anything but one blend mode, a normal blend mode.

    I would think this is true also if you took that group and made one Smart Object from them.

    So the only way to preserve all the blend modes is to not merge or flatten those layers