Skip to content

Conversation

@ThatRedox
Copy link
Member

This adds an infinite ground plane similar to the water plane.
image

Currently the texture is set to stone and isn't configurable. Currently the controls are in the Water tab so suggestions for a better place are welcome.

hit = waterPlaneIntersection(scene, ray) || hit;
}
if (scene.isGroundPlaneEnabled()) {
hit |= groundPlaneIntersection(scene, ray);
Copy link
Member

Choose a reason for hiding this comment

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

This won't call the groundPlaneIntersection method if hit is already true, eg. if the water plane was hit before. If this gets fixed, we could have ocean grounds for water world mode. 🤩

Copy link
Member Author

Choose a reason for hiding this comment

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

I think it should, |= uses the bitwise or operator so it can't get short circuited.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants