# SubViewport render a live 3D scene to a texture, shown on an in-world monitor. ```{raw} html ▶ Run in browser ``` **Tags:** `3d` `subviewport` `render-to-texture` A SubViewport renders its own subtree (a spinning cube on a blue background, viewed by its own Camera3D) into an offscreen texture every frame. That texture is fed to a Material on a flat "monitor" slab in the main scene: a live screen in the world. The monitor's feed updates each frame, proving the render-to- texture is genuinely live, not a one-shot capture. Usage: uv run python examples/features/3d/sub_viewport.py uv run python examples/features/3d/sub_viewport.py --test ## Source ```{literalinclude} ../../examples/features/3d/sub_viewport.py :language: python :linenos: ```