- Home /
Is it possible to paint an animated texture onto a terrain?
I love the underwater effect seen here: http://forum.unity3d.com/viewtopic.php?t=43733&postdays=0&postorder=asc&start=0. But I'm still too new to Unity to figure out how it works.
I thought I'd start with something more simple (I think) by painting an animated texture on the ocean floor rather then having it projected from a camera. Is that even possible?
Any tips would be greatly appreciated!
Answer by Jaap Kreijkamp · Mar 04, 2010 at 12:04 AM
Unity terrain engine doesn't support 'decals' so, unless you're very good in shader programming I don't think you can. A way to fake it more or less would be to convert the terrain to a mesh, extracting the part of the mesh that needs the decal/underwater texture and place this over the terrain with the right texture and shader offset modified to be painted above the floor.
Using a projector would probably be the simplest solution, besides making the right texture for the projector it isn't much more difficult than placing a camera. The only thing to watch is having stuff in the right layers, you probably don't want the texture be projected on the water surface so the water should be in a layer excluded from the projector.
Answer by user-1431 (google) · Mar 04, 2010 at 12:40 AM
why dont you bring in an object already painted how you want it
Answer by danielsig.du · May 05, 2010 at 11:29 AM
hey, u can also add
"IgnoreProjector" = "true"
to the water shader instead of ignoring layers ^_^
Answer by JonManatee · Aug 11, 2010 at 04:14 PM
I would point out that the splat maps are accessible in the Project view, which means that there is some possibility of modifying those splats directly to cause texture animation. The downside is that it is likely that the texture may have to be a Texture2D, meaning that replacing it with a Render Texture would not be possible. Working with a Texture2D will hav e much higher CPU overhead as I found when I tried a similar trick with the Light Maps so that I could have Light Mapped day/night cycles.
Your answer
Follow this Question
Related Questions
Terrain Brush Problem 0 Answers
grass paints in circles on terrain 2 Answers
Can't paint trees or details 0 Answers
Cannot place trees on terrain 0 Answers
Is it possible to do this for a random terrain approach? 1 Answer