render_camera_to_png
Render the Unreal Engine viewport or an off-screen camera to a PNG file at a specified path, even in headless mode.
Instructions
Force a synchronous render of the level-editor viewport (or an off-screen SceneCapture2D at arbitrary resolution) and write it to an absolute path as a PNG. Works headless/backgrounded where deferred screenshots fail.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"out_path": "<out_path>"
},
"name": "render_camera_to_png"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| out_path | Yes | Absolute filesystem path for the .png to write. | |
| width | No | Optional output width in pixels. When width and height are both > 0 (or camera_label is set), an off-screen SceneCapture2D is used instead of the live viewport. | |
| height | No | Optional output height in pixels (see width). | |
| camera_label | No | Optional level-actor label; render from that actor's world transform instead of the current viewport camera. | |
| fov | No | Optional horizontal field of view in degrees; overrides the viewport / capture FOV for this render only. |