Sometimes you may need to fix the nadir of the HDRI panoramas used for lighting and look-development.
It’s very common that your tripod is placed on the ground of your pictures, specially if you use a Nodal Ninja panoramic head or similar. You know, one of those pano heads that you need to shoot images for zenit and nadir.
I usually do this task in another specific tools for VFX panoramas like PtGui, but if you dont’ have PtGui the easiest way to handle this is in Nuke.
It is also very common when you work on a big VFX facility, that other people work on the stitching process of the HDRI panoramas. If they are in a hurry they might stitch the panorama and deliver it for lighting forgetting to fix small (or big) imperfections.
In that case, I’m pretty sure that you as lighting or look-dev artist will not have PtGui installed on your machine, so Nuke will be your best friend to fix those imperfections.
This is an example that I took while ago.One of the brackets for one of the angles. As you can see I’m shooting remote with my laptop but it’s covering a big chunk of the ground.
When the panorama was stitched, the laptop became a problem. This panorama is just a preview, sorry for the low image quality.
Fixing this in an aquirectangular panorama would be a bit tricky, even worse if you are using a Nodal Ninja type pano head.
So, find below how to fix it in Nuke. I’m using a high resolution panorama that you can download for free at akromatic.com
- First of all, import your equirectangular panorama in Nuke and use your desired colour space.
- Use a spherical transform node to see the panorama as a mirror ball.
- Change the input type to “Lat Long map” and the output type to “Mirror Ball“.
- In this image you can see how your panorama will look in the 3D software. If you think that something is not looking good in the “nadir” just get rid of it before rendering.
- Use another spherical transform node but in this case change the output type to “Cube” and change the rx to -90 so we can see the bottom side of the cube.
- Using a roto paint node we can fix whatever you need/want to fix.
- Take another spherical transform node, change the input type to “Cube” and the output type to “Lat Long map“.
- You will notice 5 different inputs now.
- I’m using constant colours to see which input corresponds to each specific part of the panorama.
- The nadir should be connected to the input -Y
- The output format for this node should be the resolution of the final panorama.
- I replace each constant colour by black colours.
- Each black colour should have also alpha channel.
- This is what you get. The nadir that you fixed as a flat image is now projected all the way along on the final panorama.
- Check the alpha channel of the result.
- Use a merge node to blend the original panorama with the new nadir.
- That’s it, use another spherical transform node with the output type set to Mirror Ball to see how the panorama looks like now. As you can see we got rid of the distortions on the ground.