Comments (8)
Yeah that kind of effect should fit well, and could be on a static switch as an option.
Didn't know about the labels - I guess so!
from crest.
Finally wading into this one since i seem to be in the mood to work on pretty effects at the moment.
I went into this with almost 0 confidence but ended up with something thats not too shabby actually!
Video: https://drive.google.com/open?id=1ZnLJqJPAHrromL8JBTP_M15_Jqt8wsTs
as usual the code is a bunch of cluttered crap with magic constants throughout. what are your initial thoughts and what kind of stuff would you like to tweak?
there are interesting RnD directions here. one would be generating the caustics properly from the waves. another would be generating approximate caustics but responding to the current wave spectra. another thing i'd like to try out is to distort the caustics based on the displacement texture, which would mean they would respond to the dynamic wave sim i think. that could look amazing i reckon..
from crest.
Woah, that looks great already! Is the movement a flipbook, or just panning and multiplying a couple of textures?
I hadn't even considered distortion. I reckon you're right, distorting based on the displacement texture would look fantastic.
As far as tweakable parameters, the most obvious are things like multiplying the light intensity, and some sort of minimum depth control (it looks like you're already fading it in the shallows?). Do caustics get more or less sharp depending on the depth they're cast on? I haven't looked at any reference, really. I don't know if that sort of thing would even be noticable.
Oh man, this will look so cool on sea creatures swimming just below the surface of the water. I can't wait to see more! You continue to impress! :D
EDIT: Whoops, missed your response about the flipbook. Yeah, looks great with just a single texture, a flipbook seems overkill.
from crest.
Oh i forgot about the talk you linked above! Looks like he uses a flipbook animation for the caustics, kinda happy i got pretty good results using a single texture :).
(btw he is hoping to release the boat demo with 2018.3, forum thread: https://forum.unity.com/threads/lwrp-boat-racing-demo-from-gdc.527104/ )
from crest.
Yeah it should work on any opaque surfaces under the water - i want to see it on the sea creatures!
Yeah its panning mixed with some distortion. Oh and i tried taking the normals from the displacement textures. it worked, but unfortunately was one of the many things that does not translate well from imagination to reality IMO. if the caustics were really being generated from the waves i think it would look quite cool, but just distorting the existing patterns with the dynamic waves was subtle and not worth the expense i think: https://drive.google.com/open?id=1yRGEayKC5Lri923iQdpVVNVGe4vbGAD1
I think of the caustics as light being focused when the water surface forms a lens and as such has a focal point/depth in the water where it will be sharpest. Of course in reality the water is a mix of different wavelengths and its more complicated, but i think assuming a focal depth is reasonable for us. I'm not sure what the best reference is but RBrucks has done some interesting work on rendering out caustics, such as https://www.youtube.com/watch?v=efh-fdJA9hw , and this focusing effect is visible. in crest i fake this by setting a mip bias (poor man's blur), which helps to get rid of the jarring sharp caustics just below the water surface.
i have added some tweak vars in the referenced commit. if you could play around with it and let me know what is/isn't working well I'd be grateful. thanks!
from crest.
btw the Texture Average Value param is a value associated with the texture and not something that should be hand tweaked. it compensates for the fact that the caustics texture is not a floating point texture that sums to a known value. when this value is configured wrong, the blurred caustic regions will appear too dark or too light (verify by flipping Caustics on and off using the toggle).
from crest.
Just dropped it in. It adds so much to the shorelines, it's fantastic! Only thing missing I can think of is an option to adjust the scale of the texture (it's already pretty good, but I'd like to tweak the scale a tiny bit).
I can't get over just how much more grounded it looks now. I'd really love to share some clips of Crest in our game some time soon!
from crest.
Oh good point :) added now and merged to master - another jewel in the crest crown, woop!!
Yeah i'd love to see more! I'm also thinking of making a 'studios using crest' section or testimonials or something and would love to discuss what could make sense here. Anyway that's probably a conversation for another day.
Let me know if you have any other feedback/issues with the caustics!
from crest.
Related Issues (20)
- Local / movable spectrums or crest shapes HOT 3
- Foam / wake vibration when approaching whirlpools HOT 20
- Pressing the Windows Key in the editor disables underwater rendering HOT 3
- Wake / foam artifacts when moving the camera quickly HOT 11
- Delayed LOD / tile enabling when using large clipping areas HOT 5
- Depth Cache not populated - Exported Image is Black HOT 8
- Water interaction is not visible when moving camera away from the sea level HOT 1
- Underwater broken with XR multi-pass rendering HOT 1
- No caustics, no shadow data and/or constant shadowing on iOS
- Error of Does not exist some Classes. HOT 1
- Sporadic gaps / precision errors in tiles. HOT 35
- SphereWaterInteraction and RegisterDynamicWavesInput do not work correctly inside a flow area HOT 11
- Activating flow in the material when oceanrenderer is running does only work in editor HOT 2
- FindObjectsSortMode HOT 3
- Enable Shader API does not function without changing underwater appearance HOT 20
- Enable Shader API causes artifacts HOT 4
- Planar Reflections issue with non-standard shaders using transparency HOT 13
- Premature tile culling during extreme camera maneuvers above the ocean HOT 1
- Portal feature broken with Unity Recorder 360 View
- Directional lights that are not active on any layer change the color of subsurface scattering HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from crest.