-
-
Notifications
You must be signed in to change notification settings - Fork 35.4k
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
Alternate GroundProjectedSkybox #27422
Comments
I would vote for just replacing it with the new code. |
beautiful! |
Thanks so much! It is possible to adjust/use the current one nicely (and hide the swimming somewhat): |
Sure, I can replace this if you want - do you still want it called |
Description
I recently tried to use
GroundProjectedSkybox
in<model-viewer>
and utterly failed. I'm not sure I can list all the problems I found, but here are a few:Screen.Recording.2023-12-22.at.18.30.49.mov
Note the sand ripple under the front tire.
I could find no clear way to fix it, so I just wrote my own. It's dramatically simpler (no custom shaders), and pretty much the only drawback is that it's slower to dynamically update the parameters, though I see no problem with this in practice since the three.js example is pretty much the only place I would imagine actually doing that on a per-frame basis.
Mine also has the advantage of making a smooth curve from the flat ground to the sky sphere:
It's not much code, but curious if anyone would like to see it upstreamed, and if so, in what form? @mrdoob @WestLangley @bhouston
Reproduction steps
Code
See my alternative here
Live example
Current: https://threejs.org/examples/?q=ground#webgl_materials_envmaps_groundprojected
Mine: https://modelviewer.dev/examples/lightingandenv/#groundedSkybox and https://modelviewer.dev/examples/augmentedreality/#ar
Screenshots
No response
Version
r159
Device
No response
Browser
No response
OS
No response
The text was updated successfully, but these errors were encountered: