0.2.0-dev Download ZIP
33 lines ·1.7 KB Raw
| 1 | <?xml version="1.0" encoding="UTF-8" ?> |
| 2 | <class name="XRVRS" inherits="Object" api_type="core" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd"> |
| 3 | <brief_description> |
| 4 | Helper class for XR interfaces that generates VRS images. |
| 5 | </brief_description> |
| 6 | <description> |
| 7 | This class is used by various XR interfaces to generate VRS textures that can be used to speed up rendering. |
| 8 | </description> |
| 9 | <tutorials> |
| 10 | </tutorials> |
| 11 | <methods> |
| 12 | <method name="make_vrs_texture"> |
| 13 | <return type="RID" /> |
| 14 | <param index="0" name="target_size" type="Vector2" /> |
| 15 | <param index="1" name="eye_foci" type="PackedVector2Array" /> |
| 16 | <description> |
| 17 | Generates the VRS texture based on a render [param target_size] adjusted by our VRS tile size. For each eyes focal point passed in [param eye_foci] a layer is created. Focal point should be in NDC. |
| 18 | The result will be cached, requesting a VRS texture with unchanged parameters and settings will return the cached RID. |
| 19 | </description> |
| 20 | </method> |
| 21 | </methods> |
| 22 | <members> |
| 23 | <member name="vrs_min_radius" type="float" setter="set_vrs_min_radius" getter="get_vrs_min_radius" default="20.0"> |
| 24 | The minimum radius around the focal point where full quality is guaranteed if VRS is used as a percentage of screen size. |
| 25 | </member> |
| 26 | <member name="vrs_render_region" type="Rect2i" setter="set_vrs_render_region" getter="get_vrs_render_region" default="Rect2i(0, 0, 0, 0)"> |
| 27 | The render region that the VRS texture will be scaled to when generated. |
| 28 | </member> |
| 29 | <member name="vrs_strength" type="float" setter="set_vrs_strength" getter="get_vrs_strength" default="1.0"> |
| 30 | The strength used to calculate the VRS density map. The greater this value, the more noticeable VRS is. |
| 31 | </member> |
| 32 | </members> |
| 33 | </class> |