Here is a quick and useful way to use expressions to make a border for stills in Action. Lets look at my action setup.
Above we can see my blue background layer.
Layer 1 is a white frame that is 1920×1080. It is a lot easier for this trick if the white border is the same resolution as the frame you want to put the border around.
And finally, we can see a still of the park that is across the street from our shop in Philly. This is where we hang out when there are building wide fire alarms.
Now, lets have a look at our finished product in action.
Nothing that earth shattering, but the white border was made with an expression and it moves with the picture frame! How did I do that? Like this. Lets crack open our animation channels.
OK. What you want to do is first open up the Media tab. Note how I named my images white and park so when I opened up the media tab, they would be clearly labeled, hey wait a second they still say media 2 and media 1! I hope Autodesk can fix this. When you have 50 images, this menu can get confusing because the media names never change. They are always media1, media2. Please feel free to educate me on how to change this, but I do not think it is possible. Note the (2) in the schematic view next to the word park. This means that this is media 2 in the media list. This is the only way I know to figure out what media is what in the list. Here is what we need to do to set up this expression. 1. Open up the media tab. 2. Select the Crop menu of the picture you want to have the border around it. 3. Now hit the copy button and onto the next step. The copy button “arms” the expression and puts it into memory. We are now ready to link it to another channel. Here is how.
OK. Select media 1, open it up and highlight the crop menu. Now push the Link button. A little e should appear next to the crop menu and you should see the expression in the field I have highlighted. If not, you have done the operation in the wrong order. What we need to do now is determine the width of the border of the white box. Click the crop button (the one with the e next to it) and hit the expression button. You should get a little something like this.
Above I have selected the menu with the expression. hit the expression button to enter the editor and the expression editor comes up. I have another expression post a few back if you want to know a little more about them. This expression came up media.2.crop. I added a -20 to it. What this does is all the crops for media 1 will be created from media 2 but with a -20 offset. So if media 2 has a crop of 100, media 2 will have a crop of 80. Lets look at the action crop menus.
Above is the crop menu. What I did was adjust my crops on Layer 2. Notice how each of the crops on Layer 1 is 20 less than on layer 2. This is due to the expression. Also note the softness. The softness is also included in this expression. Since we have not adjusted the softness on layer 2, the softness on layer 1 is -20. This will have no effect on the picture since you can not have a negative softness. If this is really bothering you or you need to adjust softness by itself, you would have to copy and link each channel of layer 2 (top, bottom, left and right) to layer 1. This is a little cumbersome to do, so I always do it the way I showed you because I rarely have to deal with softness when I do this trick. Just wanted to point it out there for ya.
***IF YOU DO NOT SEE THE WHITE FRAME CROPPING WITH AN OFFSET*******
Lets say you do all this and you start to move the crops on layer 2 and the crops on layer 1 are NOT moving as advertised. This is a bug. Simply tap any one of the top, bottom, left, right crops in layer 1 and the crops will “update” and begin to move by using the expression.
Lets look at the result.
Amazing. It is croptacular. Now lets say the clients wants a fatter border around the crop. Here is why this trick comes in so handy. Crack open the animation channel again.
In the above still I opened up the media layer, selected the expression, hit the expression button to get into the editor and then increased the number in the expression to 60. Note how my white border is now bigger. I can still adjust the crops on layer 2 but now the white border will be larger.
But what if my still is a wacky size? As we all know, IFFS needs clips with the same frame size and resolution in action or it won’t work. Also, if you have an odd size still, you will have weird results if you took an 1880×firstname.lastname@example.org still and used a 1920×1080 @1.77 for the border. Here is a good work around for that.
Above we can see my horse is a weird frame size with an even weirder aspect ration. I want to put a white border around it in action. Here is what you do. Go into the color corrector, load in your frame and make the clip black. Process the frame. Then go into the color corrector and invert the clip. Your desktop should have three clips like this.
Above I have a black clip that I made from the horse clip in the desktop color corrector. Just bring down the gamma to 0 and render it. Then load the clip into the color corrector and invert it. We now have a black and white clip the exact same size as the horse. Lets load in the white frame and the horse into action and do our crop trick. Here is what we get.
Above we can see I have loaded the horse white frame into layer3 and the horse into layer4. I have set the expression to 50 and I can crop by using layer 4 crops and layer three will follow along 50 units less. Again, the crop on layer 3 didn’t work right away so I simply touched the top crop for layer 3 and the expression “kicked in” and multi layer crops were happening quite nicely.