summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/classes/SubViewport.xml1
-rw-r--r--doc/classes/SubViewportContainer.xml4
-rw-r--r--doc/classes/Viewport.xml3
3 files changed, 4 insertions, 4 deletions
diff --git a/doc/classes/SubViewport.xml b/doc/classes/SubViewport.xml
index c439c1d016..b62c294f2c 100644
--- a/doc/classes/SubViewport.xml
+++ b/doc/classes/SubViewport.xml
@@ -4,6 +4,7 @@
Creates a sub-view into the screen.
</brief_description>
<description>
+ [SubViewport] is a [Viewport] that isn't a [Window], i.e. it doesn't draw anything by itself. To display something, [SubViewport]'s [member size] must be non-zero and it should be either put inside a [SubViewportContainer] or assigned to a [ViewportTexture].
</description>
<tutorials>
<link title="Using Viewports">$DOCS_URL/tutorials/rendering/viewports.html</link>
diff --git a/doc/classes/SubViewportContainer.xml b/doc/classes/SubViewportContainer.xml
index 050186a883..c8babb8f43 100644
--- a/doc/classes/SubViewportContainer.xml
+++ b/doc/classes/SubViewportContainer.xml
@@ -4,7 +4,7 @@
Control for holding [SubViewport]s.
</brief_description>
<description>
- A [Container] node that holds a [SubViewport], automatically setting its size.
+ A [Container] node that holds a [SubViewport]. It uses the [SubViewport]'s size as minimum size, unless [member stretch] is enabled.
[b]Note:[/b] Changing a SubViewportContainer's [member Control.rect_scale] will cause its contents to appear distorted. To change its visual size without causing distortion, adjust the node's margins instead (if it's not already in a container).
[b]Note:[/b] The SubViewportContainer forwards mouse-enter and mouse-exit notifications to its sub-viewports.
</description>
@@ -12,7 +12,7 @@
</tutorials>
<members>
<member name="stretch" type="bool" setter="set_stretch" getter="is_stretch_enabled" default="false">
- If [code]true[/code], the sub-viewport will be scaled to the control's size.
+ If [code]true[/code], the sub-viewport will be automatically resized to the control's size.
</member>
<member name="stretch_shrink" type="int" setter="set_stretch_shrink" getter="get_stretch_shrink" default="1">
Divides the sub-viewport's effective resolution by this value while preserving its scale. This can be used to speed up rendering.
diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml
index 531b09c6a0..ce61f51b9a 100644
--- a/doc/classes/Viewport.xml
+++ b/doc/classes/Viewport.xml
@@ -1,12 +1,11 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="Viewport" inherits="Node" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
- Creates a sub-view into the screen.
+ Base class for viewports.
</brief_description>
<description>
A Viewport creates a different view into the screen, or a sub-view inside another viewport. Children 2D Nodes will display on it, and children Camera3D 3D nodes will render on it too.
Optionally, a viewport can have its own 2D or 3D world, so they don't share what they draw with other viewports.
- If a viewport is a child of a [SubViewportContainer], it will automatically take up its size, otherwise it must be set manually.
Viewports can also choose to be audio listeners, so they generate positional audio depending on a 2D or 3D camera child of it.
Also, viewports can be assigned to different screens in case the devices have multiple screens.
Finally, viewports can also behave as render targets, in which case they will not be visible unless the associated texture is used to draw.