Jump to content

[Water] Changing mesh color per Vertices


Rekindled Phoenix
 Share

Recommended Posts

I've been running some realistic water experiments using leadwerks. They are time-marshaled by separate threads, dynamically adjusting the height where turbulence is added.

 

(changing the 'refraction strength' helps, but doesn't seem to outline the angled verts )

 

To outline the depth of the ripples, was thinking of changing the color of the vertices to a darker hue. What do you guys think? Since I'm new to shaders, how would I go about accomplishing this?

 

Does the community have any suggestions that could make this look better? smile.png

 

 

 

EDIT: Just found "falloff" settings, but they aren't defined in this shader pak. Attempting to add them to mesh vert and frag files...

EDIT 2: adding the falloff definitions from the ADN lib affects the mesh, but not in the way I'd expect. the vert doesn't seem to do anything, and the frag only is effected by camera angle.

Link to comment
Share on other sites

Not to sure about this, but I felt like I had to say that that water effect looks stunning! I mean we all saw the process of shadmar's ocean shader creation, and we all know how well that turned out! I have high hopes for this!

Win7 64bit, Leadwerks SDK 2.5, Visual Studio 2012, 3DWS, 3ds Max, Photoshop CS5.

 

 

 

Life is too short to remove USB safely.

Link to comment
Share on other sites

Your water should just output height and normals. The water appearance, to some degree, is independent from this. I mean you should be able to plug in our existing shaders with minimal effort.

 

FYI, Leadwerks 3 has a cross-platform thread and mutex class that is perfect for stuff like this. biggrin.png

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Thanks for your replies.

 

The objects behind the water aren't as distorted in the same manner as the diffuse (checkerboard) texture seems to be. I've modified the refraction strength variable, and that only offsets based upon the normal map, not the vertices direction.

 

Distortion via angles. Do you guys know of an effect that achieves something similar?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...