# Render texture only from a far distance.

**URL:** <https://forums.unrealengine.com/t/render-texture-only-from-a-far-distance/447604>\
**Category:** Rendering\
**Tags:** Render, disable-rendering, stop-rendering, unreal-engine, Rendering, question\
**Created:** [April 21, 2019, 8:24pm UTC](https://forums.unrealengine.com/t/render-texture-only-from-a-far-distance/447604 "2019-04-21T20:24:24Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![TheSubZer0](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TheSubZer0](https://forums.unrealengine.com/u/TheSubZer0)\
**Post date:** [April 21, 2019, 8:24pm UTC](https://forums.unrealengine.com/t/render-texture-only-from-a-far-distance/447604/1 "2019-04-21T20:24:24Z")

</div>

I’m trying to do something like this: [How to paint foliage and optimize unreal engine 4 - YouTube](https://www.youtube.com/watch?v=EThW8e4V0cE) (jump to 0:35 )

That starts to render the texture from a distance ( away) but when it’s close I want the texture to be transparent, because I have foliage in the landscape and when it’s far away the foliage will stop rendering and then it will render the texture in place.

---

<div class="post-metadata">

**Author:** ![TheSubZer0](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TheSubZer0](https://forums.unrealengine.com/u/TheSubZer0)\
**Post date:** [April 22, 2019, 12:01am UTC](https://forums.unrealengine.com/t/render-texture-only-from-a-far-distance/447604/2 "2019-04-22T00:01:21Z")

</div>

Any help??

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_11ffaa72](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_11ffaa72](https://forums.unrealengine.com/u/anonymous_user_11ffaa72)\
**Post date:** [May 30, 2019, 12:26pm UTC](https://forums.unrealengine.com/t/render-texture-only-from-a-far-distance/447604/3 "2019-05-30T12:26:05Z")

</div>

Try this:

- Create a Camera Position node and an Absolute World Position node
- Create a Distance node and connect the other two nodes as inputs to that
- Divide the output of the Distance by a large-ish number(this number is the distance after which you want the texture to be completely opaque)
- You can use the output of the Divide node as opacity/opacity mask/Lerp alpha
- Clamp the final value between 0 and 1 if anything weird happens
