ID 339293 - Batch rendering a scene without a camera will create and render from a new camera instead of throwing an error and preventing the render process
Batch render creates a new camera instead of erroring:
If your RenderSettings node's Camera parameter does not point to an existing camera and you Batch Render the scene, it will not throw an error. Instead, It will create a new camera at the 0,0,0 transform point of your Katana scene and use it to render the scene.
Disk and Batch Render errors occur later than Preview and Live Renders:
If your RenderSettings node's Camera parameter does not point to an existing camera, when performing a Preview or Live Render in Katana, the scene will check if there is a valid camera to render from and will immediately throw an error and fail to render.
Render error. Time elapsed: 0.01 sCamera '/root/world/cam/camera' not found in scene.
When you perform a Disk or Batch render, there is no immediate check to see if there is a valid camera to render from. Instead, the scene will proceed with the normal render process until a camera is required to continue and will then throw an error.
Y02002 {ERROR} No renderable camera found
This error will not stop the render process, It will continue until it throws another error.
Render stopped with exception code: 1CommandLineRender Error: doRender problemReason = Render stopped with exception code: 1Render error. Time elapsed: 4.28 sNode 'Render': Render failed with a rendering error: Render stopped with exception code: 1
Customer reported version
katana.2.6v3
Customer reported platform
ubuntu
Steps to reproduce
1. Create a scene without a CameraCreate node(PrimitiveCreate, Material, MaterialAssign, GafferThree, RenderSettings, RenderOutputDefine, and a Render node)
2. Perform Preview and Live Render on the Render node - The render will fail immediately
3. Perform a Disk Render on the Render node - The render will proceed until the camera is required and then fail
4. Save and exit Katana
5. Perform a command line batch render of the saved scene from one frame Result: Either the Render creates a camera at 0,0,0 and renders the scene or the Render will proceed until the camera is required and then fail
Workaround
If the camera does not exist, it will not appear in the Scene Graph, a callback could be created to check all camera locations before rendering a frame, similar to what the Preview and Live Render have.
Reproduced by support
The camera create bug has been reproduced in:
Katana2.6v4 - CentOS6.9 - Windows 7
Katana2.6v1 - Windows 7
Katana2.5v7 - CentOS6.9 - Windows 7
Katana2.5v1 - Windows 7
Katana2.1v6 - CentOS6.9
Katana2.1v1 - CentOS6.9
Katana2.0v1 - CentOS6.9
The Disk/Batch error issue has been reproduced in:
Katana3.2v1 - Windows 7
and all earlier versions
Earliest version tested
This issue appears to be in all versions of the product
Expected behaviour
The Batch Render should throw an error and not render the scene.
The Disk and Batch Renders should throw an error at the start of the render process.
Actual behaviour
The Batch Render creates a new camera at 0,0,0 and renders the scene.
The Disk and Batch Renders starts the render process and continues until it needs the camera and then throws an error.