Cyclo

Creates a panoramic image out of live footage frames (or just simple coverage maps). Needs a moving camera as input.

Updated: 11 March 2012

Author: makis

Compatible Nuke versions: 6.3 or later

Compatibility: Linux, Windows

c01

With this script you can create either stitched images out of sequences or just coverage maps.
It gets an animated camera (from a matchmoved sequence) and creates a group of frameholds, cameras and project3D nodes.
If you connect it to a sequence it outputs the stitched image. If you feed it with a constant you will get the coverage map.

Tested in v6.3 in Linux. Probably it works with older versions as well.

 

Usage:

0. Create a directory ('Cyclo') in your .nuke folder and put the script there. Add the following to the init.py

1
nuke.pluginAddPath('./Cyclo')

and this to the meny.py

1
2
3
4
5
toolbar = nuke.toolbar('Nodes')
menu = toolbar.addMenu('Cyclo')
 
import Cyclo
menu.addCommand('Cyclo','Cyclo.cyclo()')

 

1. Hit tab and type Cyclo. A pane will appear with a dropdown list with the available animated cameras and a number of projections input.
Choose the camera and the projections that you want to use and click ok.
- The number of projections is how many cameras and project3D nodes you want to use. It's good to start with a small number and when you finish tuning replace with another instance of Cyclo.

c03

 

2. The script then creates a node and connects it to the camera. In its panel you have the following options:
spacing: the arrangement of the projection rig in space,
near, far: the clipping planes of the cameras,
visible: toggles visibility of the cameras.
- I suggest a workflow like in the picture top-right: Plug the camera into a scene and add a sphere (or a cylinder if the movement is mostly horizontal pan). Feed the cyclo to the geometry and set the viewer to the scene node.

c02

 

3. You will get something similar to the image below. You will probably need to adjust the scale of the geometry (needs to be large enough to contain the rig).

c05

 

4. Then, hide the geo before start tuning the rig.
- You can continue without this step but the update of the texture on the surface will probably be slow.

Adjust the near and far clipping planes of the cameras to a large number like in the picture below. You can see this way the distribution of the projections in space.

c07

 

5. Use the spacing slider and the its curve in the curve editor to rearrange the cameras in space.
- The projection cameras use this curve to pick the frame (of the matchmoved camera) that will lock on. It is actually a lookup curve.
- I added this slider because my inspiration shot was a 360 heli which caused an uneven distribution of the cameras in space.

Occasionaly switch to the geometry - or a lowRes render of the texture - to check if the result is the desired.

c04

 

6. When you are ready add a crop node to your input image, add some softness, and render via a scanline render in uv mode. Voilà.
- If the cameras are not enough create another cyclo with more cameras and copy/paste the spacing curve you just created.

Sign in or register to download or rate.