{{indexmenu_n>2}}
====== Trace Mask Generator ======
----
This additional component is required for the [[weatherade_manual:snow_coverage_instance:global_surface_settings?#traces|Traces]] feature to work. You should add it to the coverage instance game object by clicking the Add Now button or from the Add Component menu.
Internally, it renders the depth of [[weatherade_manual:additional_components:trace_mask_generator?#surfaces|Surfaces]] objects from the coverage instance's position and renders the depth of [[weatherade_manual:additional_components:trace_mask_generator?#tracer_objects|Tracer Objects]] from the opposite side (bottom to top). It then creates an initial mask using these depths and then modifies it to add a more realistic trace silhouette. After all this, it generates a normal map by sampling the mask 4 times with some offsets, and packs everything into a single RGBA texture.
The Traces feature can be performance intensive because the Trace Mask Generator re-renders the scene twice more to build the trace mask, so enable this feature and configure it carefully.
===== Allow Edit in Playmode =====
Determines whether you can edit settings in play mode through the inspector UI. Useful for fine tuning the trace mask. Note: This does not take any effect in builds.
===== Resolution =====
The resolution of the generated traces mask texture. This resolution is relative to the coverage instance [[weatherade_manual:snow_coverage_instance:main_settings?#horizontal_size|Horizontal Size]]. The traces will only be visible in the current coverage area. This is done for optimization purposes.
If you change the [[weatherade_manual:snow_coverage_instance:main_settings?#horizontal_size|Horizontal Size]] of the coverage instance, the trace mask texel density will change accordingly. For example: if you have greatly increased the horizontal size of the coverage area, you should increase the Resolution to make the traces clear enough.
Try to keep this value as low as possible, since high values lead to additional overhead.
===== Mask Intensity =====
Trace mask intensity multiplier.
Increasing this value can help compensate the lower [[weatherade_manual:additional_components:trace_mask_generator?#resolution|Resolution]] value and provide clearer trails, which saves performance.
===== Blur Kernel Size =====
Amount of blur applied to the initial trace mask. Increasing this value can hit performance.
To improve performance, try to balance the area [[weatherade_manual:snow_coverage_instance:main_settings?#horizontal_size|Horizontal Size]], [[weatherade_manual:additional_components:trace_mask_generator?#resolution|Resolution]] and blur, keeping the latter two values as low as possible.
===== Normal Spread =====
The amount of sample offset when generating the trace normal map. Increasing this value can make the trace normal look wider.
===== Intersection Bias =====
The intersection offset between [[weatherade_manual:additional_components:trace_mask_generator?#tracer_objects|Trace Objects]] and [[weatherade_manual:additional_components:trace_mask_generator?#surfaces|Surfaces]]. Decreasing this value leads to earlier Tracer Objects and Surfaces contact, which results more agressive trace mask.
{{:wiki:weatherade:intersection_bias.jpg?nolink|}}
===== Depth =====
Depth of the trace. If set to 1, the snow within the trace will be pushed down to the surface of the ground. This value also depends on [[weatherade_manual:additional_components:trace_mask_generator?#intersection_bias|Intersection Bias]] and [[weatherade_manual:additional_components:trace_mask_generator?#mask_intensity|Mask Intensity]].
===== Border Height =====
Height of the outline border around the trace. Can help make traces look more detailed and natural.
===== Noise =====
Adds noise to the trace mask. Can help make traces look more detailed and natural.
==== Tiling ====
Uniform tiling of the noise.
===== Area Folloff Hardness =====
The hardness of the mask that prevents from simply disappearance of traces at the border of the coverage volume. Works same as [[weatherade_manual:snow_coverage_instance:main_settings?#area_folloff_hardness|Area Folloff Hardness]] of the coverage instance.
===== Decay Speed =====
Defines, how fast the traces will dissapear. Useful for creating effects such as snowstorms, when the traces will be pretty quickly covered by snow. If set to 0, the traces will not disappear inside the coverage area.
Increasing this value can improve performance, if [[weatherade_manual:snow_coverage_instance:global_surface_settings?#tessellation|Tessellation]] is used, because tessellation uses the trace mask to add more triangles for the traces.
===== Surfaces =====
The layer mask of the objects to be included in the process of generating the trace mask.
The fewer objects included, the better performance will be.
It is recommended that only ground surfaces be specified to improve performance.
These objects must use one of the Weatherade shaders to be visible for the Trace Mask Generator.
===== Tracer Objects =====
The layer mask of objects, that will produce the traces. The fewer objects included, the better performance will be.
It is recommended that only characters or other valuable dynamic objects be specified.
These objects must use one of the Weatherade shaders or have a special [[weatherade_manual:additional_components:tracer|Tracer]] component to become visible for the Tracer Mask Generator.