Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Foam to Waters edges and Water refactoring #38

Merged
merged 20 commits into from
May 18, 2022
Merged

Conversation

JamesTKhan
Copy link
Owner

@JamesTKhan JamesTKhan commented May 17, 2022

Adds a basic water foam effect to water edges. This may be expanded on in the future but should work well if/when some kind of wave/mesh deformation is implemented.

Foam effect adapted from http://fire-face.com/personal/water/. Since we do not currently have wave deformations the foam scrolls by offset UVs instead. This means the foam only scrolls in one direction currently but hoping to improve on this later.

  • Add softer edges and water foam effect to water intersections with other objects like shorelines.
  • Add 5 customizable properties for foam effec
  • Add new Depth Shader to support foam and soft water edges. Depth Shader was used instead of Depth Texture Attachments to try and be GLES 2.0 compatible
  • Modify behavior of asset loading on project load. Added a check on project load that makes sure standard assets are present. If they are not present, then they are loaded/created and assets have to be reloaded after that. This supports backwards compatibility.
  • Refactor duplicate code in the water shader and water widget.
  • Render wireframe when water objects is selected (I missed this in initial water PR)
  • When I developed the water feature initially I stored water settings in a MetaWater object. I have since learned that they should instead be stored in the Asset file not the Meta file. I migrated all water properties to the asset file. It should be backwards compatible but all existing water settings will be reset to default.
  • Add a WARN LogType that displays warning Log Messages in Orange color.
  • Fix issue with Shine Damper attribute not saving and loading properly
Untitled.2.mp4

.

@JamesTKhan JamesTKhan changed the title Add Foam to Waters edges and Water refactoring (DRAFT) Add Foam to Waters edges and Water refactoring May 17, 2022
@JamesTKhan JamesTKhan changed the title (DRAFT) Add Foam to Waters edges and Water refactoring Add Foam to Waters edges and Water refactoring May 17, 2022
@JamesTKhan JamesTKhan marked this pull request as ready for review May 17, 2022 20:48
@JamesTKhan JamesTKhan merged commit 3e069f1 into master May 18, 2022
@JamesTKhan JamesTKhan deleted the water-edges-depth branch May 18, 2022 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants