4 Replies Latest reply on May 2, 2016 11:52 PM by Rick Gerard

    Bug in "Shape..." dialog of mask adjustment?

    AntifreezeDesign Level 1

      I just posted this in the Bug Report for Adobe, but wanted to verify that this is a software bug, not a personal anomaly. Is anyone else having this issue, and have you found a solution?  Thanks!

       

      Problem: Setting both left and right sides of a rectangular mask to the same number in the "Shape..." mask dialog box will cause the mask to be unusable.

       

      Steps to Reproduce Bug:

      1. Create new 500x500 px comp, new comp-sized solid, and double-click rect. mask tool to create full sized mask.

      2. Adjust mask using "Shape" dialog box to set left and right sides to 250. Exit dialog.

      3.Re-enter dialog box and try to make any change to left and right side, or try to reset box to rectangle.

       

      Results:

      Changes will not be saved upon dialog exit.  This is the case when working with keyframes or not. It's also noteworthy to notice that if a mask is made in this way, then on a new keyframe the mask is "reset", the shape will not change, but I notice that the points DO rotate.

       

       

      It appears that when the mask shares identical left and right sides, it confuses the points, and cannot correctly open the mask back up.

        • 1. Re: Bug in "Shape..." dialog of mask adjustment?
          Rick Gerard Adobe Community Professional & MVP

          I'm not sure I understand or that you understand the proper use of the Shape tool for masks. You set the left, top, right and bottom edge of the mask when measured from the top right corner of the layer. The Revert To tool allows you to turn any shape drawn with the pen tool to either an ellipse or a rectangle. For example this ellipse will convert to a new rectangle when I press OK. I've drawn out guides so you can see what is going to happen.

          Screen Shot 2016-05-02 at 4.20.03 PM.png

          Press the button and the rectangle is perfectly placed exactly where I told it to go.

          Screen Shot 2016-05-02 at 4.20.12 PM.png

          If you start with any path drawn by the pen tool and revert it you'll get the rectangle but if you start with a wacky shape and do not select the revert tool then the shape is scaled to the new frame.

          Screen Shot 2016-05-02 at 4.27.11 PM.png

          The new mask shape will include the end points of the bezier handles. If the path is Roto Bezier you the mask will include the unseen tension handles for the roto bezier path.

          Screen Shot 2016-05-02 at 4.27.52 PM.png

          I've never see this tool do anything else. I think you just missed the fact that the measurements are not the boundaries of the mask but are measured from the top left corner of the layer.

          • 2. Re: Bug in "Shape..." dialog of mask adjustment?
            Tim Kurkoski Adobe Employee

            Hi Greg,

             

            I saw your bug report and was able to reproduce the problem.

             

            The problem only occurs when the left/right or top/bottom pairs have exactly the same value. Changing the left or top value will also change the right or bottom value, respectively; and changing the right or bottom value will not be saved when you OK the dialog.

             

            My intuition is that this bug is tied to the logic in the Mask Shape panel that corrects values so that the left value can never be larger than the right value, or the top value never larger than the bottom value. (This logic ensures that left is always left or right, and top is always above bottom.)

             

            This bug appears to have been in After Effects for at least several years (9.0 or earlier). Regardless, our apologies for the disruption.

            • 3. Re: Bug in "Shape..." dialog of mask adjustment?
              AntifreezeDesign Level 1

              Rick,

              I think you'll see the bug if you walk through my example.  I discovered it while trying to use a mask to create a mask that opens vertically, perfectly from the center. (not something that's fun to do without the help of the number fields).  I don't use it unless I'm keyframing and need exact measurements.

              Thanks for taking the time to explain your thoughts, though.

               

              Tim, yeah, I found that for now, the easy workaround is to (instead of left and right both being 250, for example) use something like 249.9 and 250.1.  Hopefully the anti-aliasing efforts of AE won't leave a ghostly little line.

               

              In light of what you mentioned about the algo's constraints, I noticed that adding an additional keyframe via the dialog box APPEARS to create the same mask as previously, but when I scrub the timeline, the top and bottom handles SWAP PLACES, indicating that the algorithm has automatically swapped the keyframes. In my simplistic view, it appears that the the code is doing this:

               

              If Left >= Right, swap them.

              ...when it needs to be more like:

              If Left > Right, swap them.

               

              (I know, I've just made an engineer somewhere roll their eyes at me for my overly simplistic "why don't you just do this?" summary! Sorry!

              I'm just trying to get it solved. Really.)

               

              -Greg

              • 4. Re: Bug in "Shape..." dialog of mask adjustment?
                Rick Gerard Adobe Community Professional & MVP

                I admit I misunderstood your original post. Another solution to the problem would be to leave 1 pixel separating the sides and edit the mask opacity or trim the layer to get the effect of a layer wiping on. I also find I can reproduce the bug and it happens horizontally and vertically. If you start with either a rectangle of an ellipse to start then you make the left and right side values equal (250) then you move down the timeline and move the left and right side back to their original position (0 and 500) and you select Reset to Rectangle or Ellipse  to match the original shape you created then it will work.

                 

                I also discovered that if you use transform mask by selecting the mask in the timeline and pressing ctrl/cmnd + t or by double clicking the mask path on a vertex and set up a guide so you have something to snap to that you will find the same bug if you brig the sides together. When left and right or top and bottom meet exactly you cannot use the Mask Shape tool to expand the original shape by typing in numbers.

                 

                An easier approach may be to set a keyframe right after you create the mask (alt/Option + m) then copy (ctrl/cmnd + c), then use the shape tool to get the mask to collapse, to set a new keyframe, then move the CTI to where you want the mask open and paste (ctrl/cmnd + v). I find this faster than opening the shape dialogue twice. It's definitely easier than typing in the 1/10 of a pixel. It is also my personal preference to trim the in and out points of a layer when it is supposed to disappear.

                 

                BTW, if you really want to use the Mask Shape tool twice a value difference of 1/1000 of a pixel works.... IOW if you type in 250 for left and 250.00001 for right it there is no bug. Add one more decimal point and the bug comes back.

                 

                Another solution for this transition if you are using rectangles is CC Light Wipe. Set the intensity to zero and check Reverse Transition then animate completion. The shape trick works very well with organic paths drawn with the pen tool.