Skip navigation
Currently Being Moderated

How do I view two layers alternately

May 1, 2012 5:20 AM

Is there a shortcut for viewing two layers alternately in Photoshop?

 

For example, I have two different sharpening layers which I would like to compare by switching between them both. Currently I have to turn one off and then the other on, to view the effect of one. Then to view the other one, I have to go through the same procedure. This is a very awkward method.

 

I'm thinking there must be a method whereby turning one layer on, automatically turns the other one off and clicking again reverses the process.

 

Can someone enlighten me?

 
Replies
  • Currently Being Moderated
    May 1, 2012 5:34 AM   in reply to Mahombi

    I'm thinking there must be a method whereby turning one layer on, automatically turns the other one off and clicking again reverses the process.

    And what makes you think that?

     

    You may want to look into Screenshots (in the History Panel) and/or Layer Comps and/or Actions.

     

    Edit: Scripting may be another good option and it could handle arbitrary numbers of selected Layers.

     
    |
    Mark as:
  • Currently Being Moderated
    May 1, 2012 9:07 AM   in reply to Mahombi

    I'm guessing that you need a quick switch between two images with subtle differences in order to detect them without looking away during the switch.

    As c.ptaffenbichler suggested, Layer comps can do that if you use one of the arrows at the bottom of the Layer Comps panel with two comps created. Just position the mouse cursor over one of the arrows and  keep clicking it with the desired frequency without looking at it.

    Alternatively with similar effort you can use Ctrl/Cmd + Shift + Alt + E hotkey to create a temporary flatten image layer of the document while displaying one ot the two states. Then set the layers below to display the other state, and you can keep clicking only on the eye of the flat layer without looking there.

    Also you can use Image > Duplicate to create a copy of the image and position the two windows on top of each other, then use Ctrl + Tab  and Ctrl+Shift + Tab if many other windows are open to switch between the two windows and this will animate any subtle differences.

     
    |
    Mark as:
  • Currently Being Moderated
    May 1, 2012 9:29 AM   in reply to Mahombi

    Another way if the layers don't effect any layers below such as with blending modes, etc is to Alt (option) click on the eye for the bottom of the two layers and then repeat to alternate the visibilty.

    Another way would be to make a seperate snapshot for each layer and then switch between the snapshots in the history panel.

    Or switch the order of the layers in the layers panel and use Ctrl (cmd)+Z to alternate the view. (this is undo/redo if your using the default undo and step back shortcuts)

     
    |
    Mark as:
  • Currently Being Moderated
    May 2, 2012 4:04 AM   in reply to Mahombi

    In case you ever want to sqwitch through a number of Layers larger than two a Scripting solution might be more convenient than the other methods, so in that case you could also ask over at

    http://forums.adobe.com/community/photoshop/photoshop_scripting

     
    |
    Mark as:
  • Currently Being Moderated
    May 2, 2012 4:18 AM   in reply to Mahombi

    there's no shortage of shortcuts for other moves

    That seems debatable.

    As far as I can tell most default Keyboard Shortcuts trigger one operation that corresponds to one Menu or Panel item – whereas what you want is dependent on the way you structure your files and involves variables that the programmers of Photoshop can hardly be expected to predict.

    The workaround possibilities seem reasonable to me and could (some at least) be assigned Keyboard Shortcuts of your liking if the task merits such for you.

     

    You could always post a Feature Request over at

    http://feedback.photoshop.com/photoshop_family/

     
    |
    Mark as:
  • Currently Being Moderated
    May 2, 2012 6:30 AM   in reply to Mahombi

    a script may even be overkill and may require a number of clicks anyway...

     

    in the history panel flyout menu, click history options, check the "make layer visability changes undoable" box, and check the "allow non linear history box": click ok.... (now history will "record" layer visability changes and allow deleting of individual history states)

     

    from now on cmd : select the layers in question, r-click the eye, hide layer, then show one, hide it, show other ... or what ever workflow you prefer..

     

    then you can either opt-cmd-z (prev state) or shift-cmd-z (next state) to toggle, or you can (best way) "toggle" click on the relevent history states in the panel, and even delete the unwanted history state/s allowing for plain ol cmd-z...

     

     

    G

     
    |
    Mark as:
  • Currently Being Moderated
    May 2, 2012 7:04 AM   in reply to Grant H

    a script may even be overkill and may require a number of clicks anyway...

    It may well be, but one can set it up to hide all but one of selected Layers (if more than one of them is visible) and on following iterations hide the one visible Layer and show the next one.

     
    |
    Mark as:
  • Currently Being Moderated
    May 2, 2012 10:45 PM   in reply to Mahombi

    If you want to give a Script a try, paste the following text into a new file in ExtendScript Toolkit (part of Photoshop’s installation, Applications/Utilities/Adobe Utilities/ExtendScript Toolkit CS4 or /Applications/Utilities/Adobe Utilities-CS5/ExtendScript Toolkit CS5) and save it as a jsx-file into Photoshop’s Presets/Scripts-folder.

    After restarting Photoshop the Script should be available under File > Scripts and can be assigned a Keyboard Shortcut directly, recorded into an Action, (in CS4 and CS5) be used in a Configurator-Panel or started from ExtendScript Toolkit directly.

     

    The Script hides all but one of the selected Layers (no Groups), if only one of the selected Layers is visible it hides this one and shows the next.

     

    // show one of the selected layers in turn;
    // 2012, use at your own risk;
    #target photoshop
    if (app.documents.length > 0) {
    var myDocument = app.activeDocument;
    var theLayers = GetSelectedLayers();
    //alert (theLayers.join("\n"));
    var theVis = [];
    // hide the layers;
    for (var m = 0; m < theLayers.length; m++) {
              if (theLayers[m].visible == true) {theVis.push([theLayers[m].visible, m, theLayers[m]])};
              theLayers[m].visible = false
              };
    // show one layer;
    if (theVis.length == 1) {
              var theNumber = theVis[0][1];
              theVis[0][2].visible = false;
              if (theNumber == theLayers.length - 1) {var theNext = 0}
              else {theNext = theNumber + 1};
              theLayers[theNext].visible = true
              }
    else {
              theLayers[0].visible = true
              };
    };
    ////////////////////////////////////
    // function by paul mr;
    function GetSelectedLayers() {
    var A=[];
        var desc11 = new ActionDescriptor();
            var ref9 = new ActionReference();
            ref9.putClass( stringIDToTypeID('layerSection') );
        desc11.putReference( charIDToTypeID('null'), ref9 );
            var ref10 = new ActionReference();
            ref10.putEnumerated( charIDToTypeID('Lyr '), charIDToTypeID('Ordn'), charIDToTypeID('Trgt') );
        desc11.putReference( charIDToTypeID('From'), ref10 );
        executeAction( charIDToTypeID('Mk  '), desc11, DialogModes.NO );
    var gL = activeDocument.activeLayer.layers;
    for(var i=0;i<gL.length;i++){ 
    A.push(gL[i]); 
    } 
    executeAction( charIDToTypeID('undo'), undefined, DialogModes.NO );
    return A;
    };
    
     
    |
    Mark as:
  • Currently Being Moderated
    May 3, 2012 2:16 AM   in reply to Mahombi

    Hi

     

    Use ctrl and rectangular brackets []

    to selecting alternate layers

     

    ------------------------------------------

     

    Message was edited by: Peter Spier

     
    |
    Mark as:
  • Trevor Dennis
    5,853 posts
    May 24, 2010
    Currently Being Moderated
    May 3, 2012 3:46 AM   in reply to maytaurus

    maytaurus wrote:

     

    Hi

     

    Use ctrl and rectangular brackets []

    to selecting alternate layers

     

     

    Ctrl/Cmd [ or ] move layers up and down the stack.  There are other suggestion further up the thread that will help.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points