Skip to content

Camera settings

camera_settings() spawns a table of cinema cameras in front of you. Each column is a camera, each row a setting. Press C to look through the next camera.

from camera_settings import camera_settings
camera_settings()

Using the table

  • Column A names each setting with its range, such as Focal length mm [4, 1000].
  • Row 1 holds the camera names. Every other column is a camera.
  • To add a camera, type a name into the empty column at the right. A new empty column appears when you leave the cell.
  • A blank value uses the engine default (post-process rows aren't overridden; Panini is off).
  • Editing a cell of the active camera applies it at once.
  • C cycles the drone's first-person camera through the columns.

The table is saved to Saved/Tables/camera_settings.zarr after every edit and loaded when Starcel starts.

Settings

Setting Range Default
Focal length mm 4 – 1000 35
Aperture f-stop 0.5 – 32 2.8
Lens min / max f-stop 0.5 – 32 / 1 – 64 1.2 / 22
Diaphragm blades 4 – 16 7
Sensor width / height mm 1 – 100 24.89 / 18.67
Depth of field 0/1 0 – 1 1
Focus distance cm 1 – 100000 1000
Ortho 0/1 0 – 1 0
Ortho width cm 10 – 100000 2000
Panini D / S 0 – 1 / -1 – 1 0 / 0
Screen percentage 10 – 400 100
Exposure bias EV -15 – 15 engine
Bloom intensity 0 – 8 engine
Vignette 0 – 1 engine
Film grain 0 – 1 engine
Motion blur 0 – 1 engine
Chromatic aberration 0 – 5 engine

Placing it yourself

from unreal_engine import FVector
camera_settings(location=FVector(0, -1200, 600))   # top left corner of the table

Calling camera_settings() again replaces the table you spawned before.

Cameras without the table

For a one-off camera, use spawn('camera', ...) with a preset:

from ue_spawn import spawn
spawn('camera', camera_preset='bokeh_portrait')

In the tests

Copied from the code when this site is built.

From the tests: test_camera_settings (Content/Scripts/test_spawn.py:2003)
def test_camera_settings(base_y=0):
    """Spawn the camera settings table: a column per camera, C cycles them.
    Replaces a camera settings table spawned before."""
    from camera_settings import camera_settings, cameras, CONTROLLER

    t0, actor, extra = time.monotonic(), None, ''
    try:
        extra = camera_settings(location=FVector(0, base_y + 100, 1400))
        actor = CONTROLLER.actor
        names = [name for name, _ in cameras(CONTROLLER.table)]
        _log(f'  cameras: {names}')
        if not names:
            actor, extra = None, 'the table has no cameras'
    except Exception as e:
        _log_exception('camera_settings', e)
    return _result('camera_settings', actor, extra=extra,
                   expected='a table with at least one camera column',
                   elapsed=time.monotonic() - t0)

View it on GitHub