diff options
author | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-08-29 14:44:09 +0200 |
---|---|---|
committer | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-10-08 18:22:10 +0200 |
commit | 73c6e19acc69b7367c4fa67cd4377e2207faf898 (patch) | |
tree | 35720ecbf3c231606efecb3c01fc603fb3a193a0 /doc | |
parent | a5a52233bc1327d8943c0a2a3866aa314371edec (diff) |
Allow any floating-point value as a 3D rendering scale option
This allows for finer control over 3D rendering resolution.
Supersampling can also be performed by setting a 3D rendering
resolution above 1.0, which is useful for offline rendering or
for very high-end GPUs.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/classes/ProjectSettings.xml | 7 | ||||
-rw-r--r-- | doc/classes/RenderingServer.xml | 12 | ||||
-rw-r--r-- | doc/classes/Viewport.xml | 17 |
3 files changed, 9 insertions, 27 deletions
diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml index b3872121bf..5403bd48d5 100644 --- a/doc/classes/ProjectSettings.xml +++ b/doc/classes/ProjectSettings.xml @@ -1479,11 +1479,12 @@ </member> <member name="rendering/2d/snap/snap_2d_vertices_to_pixel" type="bool" setter="" getter="" default="false"> </member> - <member name="rendering/3d/viewport/scale" type="int" setter="" getter="" default="0"> - Scale the 3D render buffer based on the viewport size. The smaller the faster 3D rendering is performed but at the cost of quality. + <member name="rendering/3d/viewport/scale" type="float" setter="" getter="" default="1.0"> + Scales the 3D render buffer based on the viewport size and displays the result with linear filtering. Values lower than [code]1.0[/code] can be used to speed up 3D rendering at the cost of quality (undersampling). Values greater than [code]1.0[/code] can be used to improve 3D rendering quality at a high performance cost (supersampling). See also [member rendering/anti_aliasing/quality/msaa] for multi-sample antialiasing, which is significantly cheaper but only smoothens the edges of polygons. + [b]Note:[/b] This property is only read when the project starts. To change the 3D rendering resolution scale at runtime, set [member Viewport.scale_3d] instead. </member> <member name="rendering/anti_aliasing/quality/msaa" type="int" setter="" getter="" default="0"> - Sets the number of MSAA samples to use (as a power of two). MSAA is used to reduce aliasing around the edges of polygons. A higher MSAA value results in smoother edges but can be significantly slower on some hardware. + Sets the number of MSAA samples to use (as a power of two). MSAA is used to reduce aliasing around the edges of polygons. A higher MSAA value results in smoother edges but can be significantly slower on some hardware. See also [member rendering/3d/viewport/scale] for supersampling, which provides higher quality but is much more expensive. </member> <member name="rendering/anti_aliasing/quality/screen_space_aa" type="int" setter="" getter="" default="0"> Sets the screen-space antialiasing mode for the default screen [Viewport]. Screen-space antialiasing works by selectively blurring edges in a post-process shader. It differs from MSAA which takes multiple coverage samples while rendering objects. Screen-space AA methods are typically faster than MSAA and will smooth out specular aliasing, but tend to make scenes appear blurry. diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml index 65b7e53ecd..6f19114c16 100644 --- a/doc/classes/RenderingServer.xml +++ b/doc/classes/RenderingServer.xml @@ -3102,7 +3102,7 @@ <method name="viewport_set_scale_3d"> <return type="void" /> <argument index="0" name="viewport" type="RID" /> - <argument index="1" name="scale" type="int" enum="RenderingServer.ViewportScale3D" /> + <argument index="1" name="scale" type="float" /> <description> Sets the scale at which we render 3D contents. </description> @@ -3918,16 +3918,6 @@ </constant> <constant name="VIEWPORT_DEBUG_DRAW_OCCLUDERS" value="23" enum="ViewportDebugDraw"> </constant> - <constant name="VIEWPORT_SCALE_3D_DISABLED" value="0" enum="ViewportScale3D"> - </constant> - <constant name="VIEWPORT_SCALE_3D_75_PERCENT" value="1" enum="ViewportScale3D"> - </constant> - <constant name="VIEWPORT_SCALE_3D_50_PERCENT" value="2" enum="ViewportScale3D"> - </constant> - <constant name="VIEWPORT_SCALE_3D_33_PERCENT" value="3" enum="ViewportScale3D"> - </constant> - <constant name="VIEWPORT_SCALE_3D_25_PERCENT" value="4" enum="ViewportScale3D"> - </constant> <constant name="SKY_MODE_AUTOMATIC" value="0" enum="SkyMode"> </constant> <constant name="SKY_MODE_QUALITY" value="1" enum="SkyMode"> diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml index cdb9e7632b..e79cf0d233 100644 --- a/doc/classes/Viewport.xml +++ b/doc/classes/Viewport.xml @@ -204,7 +204,7 @@ <member name="lod_threshold" type="float" setter="set_lod_threshold" getter="get_lod_threshold" default="1.0"> </member> <member name="msaa" type="int" setter="set_msaa" getter="get_msaa" enum="Viewport.MSAA" default="0"> - The multisample anti-aliasing mode. A higher number results in smoother edges at the cost of significantly worse performance. A value of 4 is best unless targeting very high-end systems. + The multisample anti-aliasing mode. A higher number results in smoother edges at the cost of significantly worse performance. A value of 2 or 4 is best unless targeting very high-end systems. See also [member scale_3d] for supersampling, which provides higher quality but is much more expensive. </member> <member name="own_world_3d" type="bool" setter="set_use_own_world_3d" getter="is_using_own_world_3d" default="false"> If [code]true[/code], the viewport will use the [World3D] defined in [member world_3d]. @@ -212,8 +212,9 @@ <member name="physics_object_picking" type="bool" setter="set_physics_object_picking" getter="get_physics_object_picking" default="false"> If [code]true[/code], the objects rendered by viewport become subjects of mouse picking process. </member> - <member name="scale_3d" type="int" setter="set_scale_3d" getter="get_scale_3d" enum="Viewport.Scale3D" default="0"> - The scale at which 3D content is rendered. + <member name="scale_3d" type="float" setter="set_scale_3d" getter="get_scale_3d" default="1.0"> + Scales the 3D render buffer based on the viewport size and displays the result with linear filtering. Values lower than [code]1.0[/code] can be used to speed up 3D rendering at the cost of quality (undersampling). Values greater than [code]1.0[/code] can be used to improve 3D rendering quality at a high performance cost (supersampling). See also [member msaa] for multi-sample antialiasing, which is significantly cheaper but only smoothens the edges of polygons. + To control this property on the root viewport, set the [member ProjectSettings.rendering/3d/viewport/scale] project setting. </member> <member name="screen_space_aa" type="int" setter="set_screen_space_aa" getter="get_screen_space_aa" enum="Viewport.ScreenSpaceAA" default="0"> Sets the screen-space antialiasing method used. Screen-space antialiasing works by selectively blurring edges in a post-process shader. It differs from MSAA which takes multiple coverage samples while rendering objects. Screen-space AA methods are typically faster than MSAA and will smooth out specular aliasing, but tend to make scenes appear blurry. @@ -275,16 +276,6 @@ </signal> </signals> <constants> - <constant name="SCALE_3D_DISABLED" value="0" enum="Scale3D"> - </constant> - <constant name="SCALE_3D_75_PERCENT" value="1" enum="Scale3D"> - </constant> - <constant name="SCALE_3D_50_PERCENT" value="2" enum="Scale3D"> - </constant> - <constant name="SCALE_3D_33_PERCENT" value="3" enum="Scale3D"> - </constant> - <constant name="SCALE_3D_25_PERCENT" value="4" enum="Scale3D"> - </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_DISABLED" value="0" enum="ShadowAtlasQuadrantSubdiv"> This quadrant will not be used. </constant> |