diff options
Diffstat (limited to 'Shaders')
| -rw-r--r-- | Shaders/ray_march.cginc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Shaders/ray_march.cginc b/Shaders/ray_march.cginc index af4d1a4..5a9524a 100644 --- a/Shaders/ray_march.cginc +++ b/Shaders/ray_march.cginc @@ -136,7 +136,8 @@ float stt_map(float3 p, out int obj_id, out float2 text_uv) box_scale.y *= ceil(p3r); box_scale.z *= ceil(p3r); - float d = distance_from_box(pp, box_scale); + // Only use calculation when in phase 3. + float d = lerp(1000, distance_from_box(pp, box_scale), ceil(p3r)); text_uv = (clamp(pp.xz, -1 * box_scale.xz, box_scale.xz) / box_scale.xz); text_uv = (text_uv + 1) / 2; |
