- Home /
Fading Between 2 Textures.
how can i fade between 2 textures on a single material, like i have 2 water textures, and i want to fade in between them, is this possible.
I dont want to use shader for this purpose because i am already using a custom shader on my material and i am not a shader writer.
This is a repeated question, but i posted ir because i could not find the satisfactory answer. Thanks.
Fading between textures needs to happen in your shader. It might be possible to hack a solution which doesn't require editing the shader, but editing the shader is the proper solution.
Hi, if you look at my last comment in this post I give some links to some youtube videos that I found recommended in a post here a while back. A guy explains how to fade between two Skyboxes with C# code and an adjusted shader(which he shows you how to do) for the Skybox $$anonymous$$aterial. This may be of some use in helping you to correctly adjust your shader and make use of this change via scripting :
http://answers.unity3d.com/questions/830944/change-skybox-via-script-help.html#answer-830976
Answer by Immanuel-Scholz · Nov 14, 2014 at 12:18 PM
If you are standing on a wall with a gun between your eyes and your shader supports transparency, you can duplicate the gameObject with the renderer and move the second a couple of millimeter backwards and then set the alpha of the front-object to "blend".
But no, you do not want to do this. Instead you want to change the shader. ;)
hmm, i will try it, but i dont know how actually to write a shader, or even how to mix 2 shaders...
Gotta learn sometime! I still struggle with a lot of shader stuff, but having a basic knowledge is extremely helpful.
Your answer
Follow this Question
Related Questions
Assigning UV Map to model at runtime 0 Answers
Texture uv's offest in distance? 0 Answers
Overlay text over multiple cubes 1 Answer
How to get texture coordinates without using MeshCollider? 0 Answers