-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
From 1.37, GLTF shader paths are relative, even when starting with a slash #5844
Comments
Definitely sounds like a bug. There's been some discussion of root-relative paths on the official glTF repo lately, but nothing that should prevent this from working. |
Sorry to bump this but can we expect a fix in upcoming releases or is this something I should be looking into myself? Thanks. |
@xtassin we would love to get this fix in, but no one has had a chance to look at it yet. It should be pretty straight forward so I think it would make a great first pull request if you have the time or desire to tackle it yourself. If not, thanks for bringing it to our attention anyway and I marked this a priority so we don't forget about it. |
Actually I recently opened a PR to add If someone has time to run |
All usage of uri.resolve have been replaced by joinUrls in model.js (and possibly in other places) during "Misc changes and helpers from 3d-tiles #5249" The fix could be to handle root relative url in joinUrls but I am not sure of your view on that. |
I checked that this has since been fixed after the resource loading overhaul. Paths starting with a slash should now point to the server root directory. |
Hi,
I used to specify custom shaders in my GLTF files in this manner:
"uri": "/shaders/mappedReflectiveFS.glsl"
This should load the file from the root of the web host (http://domain.com/shaders/mappedReflectiveFS.glsl)
Instead, and starting with Cesium 1.37, the shaders are loaded relative to the GLTF's directory even if the uri starts with a slash.
Regards,
Xavier.
The text was updated successfully, but these errors were encountered: