Stylized Water Shader 2.0
After its initial release in September 2016, the package sees a major version bump to version 2.0.0.
With this version the previously deprecated Desktop shaders have been made obsolete and removed from the package. These are now replaced by the Desktop shader previously marked as “Beta”. This is now the default Desktop shader and has been extended with the features as outlined in this post.
In doing so, this asset is now supported in Unity 2018.1 and newer.
New features
*Not available on mobile
Color gradient*
Rather than using the two color fields for deep and shallow water, a gradient can be used for finer control.
Orthographic cameras
A much requested feature, and a common pain point for water shaders in general. Users with an orthographic camera will now be able to use the full feature set, such as depth and intersection effects.
Distance-based tiling reduction*
Particularly useful for scenarios where the camera can get both far and near the water. At further distances, a normal map, 10 times larger will be blended in
Vertex color support
Through a toggle, vertex colors can be used to denote where the intersection effect should show, or where the water should be transparent.
Reflection blur*
Something often observed in real water, reflections can now be blurred vertically.
Demo scenes
The previous demo scene and assets have been removed and replaced by 3 separate demo scenes: island, lake and pond. Which demonstrate a practical use of the shader.
Two trees and a set of rocks were used as dressing and you’re free to use these!
UX improvements
The inspector window has had a facelift, parameters now also use less jargon.
Sections are now only visible one at a time, to avoid an information overload.
Through a new window found under the “Help” menu, you can check if a version update is available.
Water VFX
A set of matching water particle effects have been added.
A mobile shader variant is included, which is optimized for the platform.
Mobile
The previous “Mobile Advanced” and “Mobile Basic” shaders have been combined into a single uber shader. Features such as lighting can be toggled to disable unnecessary rendering. It’s now up to 37% faster, despite having much more features than before.
As opposed to the previous version, it now features:
- Heightmap wave animation
- Orthographic camera support
- Different lighting modes
- Depth color (light absorption)
- Wave tinting
- Wave direction configuration
- Foam speed
VR
The package has been tested for compatibility with desktop VR. Adjustments were made to support Single-Pass Stereo Rendering.
Realtime reflections remain unsupported and will be automatically disabled.
Changelog:
Added:
– 3 new demo/example scenes: Island, lake and pond.
– 4 water VFX assets
– New Mobile uber shader (up to ~37% faster)
– Orthographic camera support
– Lighting modes (Unlit/Basic/Advanced)
– Vertex painting support for intersection and opacity
– Support for Single-Pass Stereo rendering
– Reflection blurring
– Tiling deduction toggle (Desktop only)
– Color gradient feature (Desktop only)
– Additional waves layer toggle, for improved wave animations
– Surface highlight and Intersection distortion parameters
– Custom heightmap option
Changed:
– Inspector UX improvements, sections now function as an accordion
– Tiling is now separated for each feature (Normals/Waves/Intersection/Foam)
– “Surface highlights” is now called “Foam” for clarity
– Depth and Intersection maximum value ranges have been increased
– Desktop shader no longer uses tessellation, for wider compatibility
– Compressed textures option now automatically bakes textures when value is changed
– Increased UV size of included meshes to be more in line with World-space tiling
– Wave direction now also allows negative values
– “Custom” toggles for intersection and waves is now a dropdown menu option
Removed:
– Old demo scene and related assets
– Mobile Advanced and Mobile Basic shaders
hello, are you planning to support pipelines in the future ?
Most likely, it’s only going to be more adopted over time. Though, I still have to look into the changes I’d need to make in order to support one.
That looks really cool! I especially like some of the particle effects and the vertex color transparency.
Small question, how editable are the particle effects? Looking at the little “circle” wave you have there, would it be possible to mod that to lines/wedges? I’m thinking it could be a good way to display currents that way – or would that be a performance issue?