About Proxies

Updated 10/10/00

If you are working with a complex script, the interactivity may slow down because you are working with large resolution images. An alternative to working with the full resolution is to use lower resolution, or proxy, images. By switching to proxies, Shake re-executes the same script, but on a lower resolution image. The speed increase is substantial. If you use 1/2 resolution proxies, your increase should be approximately fourfold, as you have half res in both the X and Y axes.

Pixel-based functions like Pans and Blurs are internally multiplied down to compensate for the drop in resolution, so everything will be relatively positioned the same. However, some filters like DilateErode, Grain, and Median (Blur is fine, though) will have different results since they generally work on a single pixel level. When finalizing your images and tuning with these filters, we recommend going up to full resolution and limiting your render area with a SetDOD node or ViewerScript3.

Because the process inherently throws away data, we recommend only tracking on full resolution images. Otherwise, you are automatically introducing an inaccuracy of several pixels in any direction.

Each proxy technique has an additional mode for aspect ratio - you can temporarily drop into a different aspect ratio by scaling just the Y axis. For more information on aspect ratios, jump here.

Shake has three different methods for working with proxy images: On-the fly proxies, interactive proxies, and pre-generated proxies. All can be used simultaneously.

A special note on using proxies and Z-channel images. Because the proxies normally filter the image down, you will get artifacting if you use proxies for images with Z channels in them, kinda like this:

If you switch the filtering type (available in the proxy sub-trees), you can help reduce this artifacting. Note, however, that the proper filters are also low-quality filters, so all other effects will be diminished in quality. This sample is using a box blur:

 

On-the fly proxies with proxyScale

The first method is to simply turn on proxyScale in the Globals tab by pressing the percentage of the original size you want to use (or use -proxyscale .5 in the command-line). This will take the images for the current frame, resize them down, and store the low-res proxies in the cache. The composite will then be recalculated at this new resolution.

This has several advantages and disadvantages:

The proxyScale can be quickly turned on and off without returning to the Globals tab by using the Use Proxy button at the top of the interface: . If you have not yet entered a proxyScale (i.e., something other than 1), this button will have no effect.

 

Interactive proxies with interactiveScale

This is similar to the use of proxyScale, except it is only engaged when you move a slider. To use it, enter an interactiveScale less than 1. For example, attach a Move2D to a Checker node, and change the interactiveScale to 1/10. When you modify the Move2D, the resolution drops down, and returns to full resolution when you release the mouse. This is ideal for functions like RBlur or Defocus. You can use this with proxyScale, so if each was set at 1/2, the interactiveScale is actually at 1/4 of the full resolution.

This mode will not change the output resolution, so there is no need for a command-line over-ride.

 

Pre-generated proxies with pixelScale

This technique requires some set-up work, but gives you the fastest and most efficient renders. The technique is to take each full-resolution plate (we are generally assuming this is to be used with HD resolution or higher) and generate several lower resolution images. The script is put together with the low resolution images. When the script is finished, you switch in the full resolution images. To make sure all elements are properly positioned, you enter a pixelScale that is the same ratio as the full resolution plates to the low resolution plates. You can also start with the low-res plates and immediately enter a pixelScale and pixelRatio before starting your script. When you switch in the high-res elements, you return both to 1.

For example, you have 2.35 anamorphic film elements that are 2048x1556. You generate proxies that are approximately 601 resolution with the following command-line:

shake my_full_res_images.#.cin -zoom .3515 .1496 -bytes 1 -fo my_low_res_images.#.cin -t 1-100

I got the .3515 by dividing 720, my target resolution, by 2048. I got the .1496 by multiplying .3515 by dividing .3515 by 2.35, my aspect ratio. This will generate 100 flattened 8-bit images at 720x232 resolution. We drop the bit depth for speed as well. We therefore have two choices:

This has several advantages and disadvantages, all them basically the inverse of proxyScale:

I created some macros to help with this in the Cookbook. It isn't perfect, but it works.