:github_url: hide .. Generated automatically by doc/tools/makerst.py in Godot's source tree. .. DO NOT EDIT THIS FILE, but the ViewportTexture.xml source instead. .. The source is found in doc/classes or modules//doc_classes. .. _class_ViewportTexture: ViewportTexture =============== **Inherits:** :ref:`Texture2D` **<** :ref:`Texture` **<** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` Texture which displays the content of a :ref:`Viewport`. Description ----------- Displays the content of a :ref:`Viewport` node as a dynamic :ref:`Texture2D`. This can be used to mix controls, 2D, and 3D elements in the same scene. To create a ViewportTexture in code, use the :ref:`Viewport.get_texture` method on the target viewport. Properties ---------- +---------------------------------+--------------------------------------------------------------------+------------------+ | :ref:`bool` | resource_local_to_scene | **O:** ``true`` | +---------------------------------+--------------------------------------------------------------------+------------------+ | :ref:`NodePath` | :ref:`viewport_path` | ``NodePath("")`` | +---------------------------------+--------------------------------------------------------------------+------------------+ Property Descriptions --------------------- .. _class_ViewportTexture_property_viewport_path: - :ref:`NodePath` **viewport_path** +-----------+-----------------------------------+ | *Default* | ``NodePath("")`` | +-----------+-----------------------------------+ | *Setter* | set_viewport_path_in_scene(value) | +-----------+-----------------------------------+ | *Getter* | get_viewport_path_in_scene() | +-----------+-----------------------------------+ The path to the :ref:`Viewport` node to display. This is relative to the scene root, not to the node which uses the texture.