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

fix: fix wetness calculation logic #151

Merged
merged 4 commits into from
Jan 10, 2024
Merged

Conversation

TheRiverwoodModder
Copy link
Contributor

@TheRiverwoodModder TheRiverwoodModder commented Jan 4, 2024

  • Added Fog wetness
  • Refactored wetness calculation logic and made Snow & Rain detection more robust
  • Added settings for Fog & Snow Max Wetness
  • Moved Max Wetness to CPU to allow for unique values for rain fog, and snow max wetness
  • Included Shore Wetness in the Enable Wetness toggle
  • Fixed the perPassWetnessEffects struct in WetnessEffects.hlsli

Edit: Removed snow and fog calculation from this PR. Will reintroduce in a later build.

Version = 0-9-3
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we're doing semantic versioning, this should be 0.10.0 since it's a new feature.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WIll use semantic versioning in future updates.

Copy link
Collaborator

@alandtse alandtse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't test the effect, but if @doodlum is good with it I just have minor comments.

@doodlum
Copy link
Owner

doodlum commented Jan 4, 2024

To do fog, please do something along the lines of:

  • Use reversed fog code and run on the GPU at a given distance
  • Fog wetness is equal to the brightness * alpha of the fog at that given distance

Otherwise it's going to be too unreliable.

You don't need to extract any information from the weather itself, it's already available in Sky. We only needed to use the weathers to get that particle information, afaik.

@TheRiverwoodModder TheRiverwoodModder changed the title feat: Added Fog wetness and refactored rain and snow logic chore: Refactored rain logic Jan 6, 2024
@alandtse alandtse changed the title chore: Refactored rain logic refactor: refactor rain logic Jan 8, 2024
@alandtse
Copy link
Collaborator

alandtse commented Jan 8, 2024

What's the main benefit of the refactor? Performance, fix, feature, maintainability? Not a big deal but just trying to find a better description than chore/refactor which are not version incrementing.

@TheRiverwoodModder
Copy link
Contributor Author

In that case, "Fix" is probably the best prefix. It fixed several issues and improved the weather transition curve.

@alandtse alandtse changed the title refactor: refactor rain logic fix: fix wetness calculation logic Jan 9, 2024
@doodlum doodlum merged commit 7221579 into doodlum:dev Jan 10, 2024
7 of 8 checks passed
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.

3 participants