Up to date
This page is up to date for Godot
If you still find outdated information, please open an issue.
Provides the content of a Viewport as a dynamic texture.
To create a ViewportTexture in code, use the Viewport.get_texture method on the target viewport.
NodePath viewport_path =
The path to the Viewport node to display. This is relative to the scene root, not to the node that uses the texture.
Note: In the editor, this path is automatically updated when the target viewport or one of its ancestors is renamed or moved. At runtime, the path may not be able to automatically update due to the inability to determine the scene root.