|
@@ -1,12 +1,11 @@
|
|
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<?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">
|
|
<class name="Viewport" inherits="Node" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
|
|
<brief_description>
|
|
<brief_description>
|
|
- Creates a sub-view into the screen.
|
|
|
|
|
|
+ Base class for viewports.
|
|
</brief_description>
|
|
</brief_description>
|
|
<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.
|
|
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.
|
|
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.
|
|
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.
|
|
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.
|
|
Finally, viewports can also behave as render targets, in which case they will not be visible unless the associated texture is used to draw.
|