Skip to content

Auto-batching & render settings β€” at the terminal

cli tutorial Intermediate ⏱ 4 min vgai 0.1.0

Prerequisites: Rendering Β· cameras & meshes

What you'll learn

  • See the full scene rendering-settings registry and its defaults
  • Know that auto-batching + render settings are engine features backed by tests

What you'll build: A terminal look at the rendering-settings registry and the render-settings/auto-batch tests.

The rendering-settings registry and the transparent auto-batcher are engine features β€” the manual page Performance: auto-batching & render settings explains them; here they are, real, at the terminal (captured output below).

# transcript pending capture β€” run: node site/media/capture-cli.mjs
Terminal β€” Auto-batching & render settings β€” at the terminal Β· captured by site/media/capture-cli.mjs
  1. List the rendering-settings registry. RENDER_FEATURES (packages/engine/src/render/render-features.ts) is the single source of the scene-level environment.rendering toggles β€” autoBatch, frustumCulling, lod, shadows, postProcessing, resolutionScale, antialias, backend β€” each printed with its default (all on; resolutionScale 1; backend "auto"). These are the same fields the editor’s Rendering environment section exposes.

  2. Run the render-settings tests. vitest run render-settings exercises how those settings are applied (render-settings.ts) and the transparent auto-batcher (auto-batcher.ts / render-batch-system.ts) β€” real passing tests, not a claim.

Recap

New functionality

  • Listed the scene rendering-settings registry + defaults
  • Ran the render-settings / auto-batch tests

New concepts & skills

  • environment.rendering toggles come from one registry (RENDER_FEATURES)
  • auto-batching is transparent + gated opt-out
  • the editor Rendering section edits these same fields

Next lesson β†’ Performance (manual)