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

Re-loading cubemaps fail to load associated textures #6358

Closed
Astra307 opened this issue May 14, 2024 · 2 comments · Fixed by #6397
Closed

Re-loading cubemaps fail to load associated textures #6358

Astra307 opened this issue May 14, 2024 · 2 comments · Fixed by #6397

Comments

@Astra307
Copy link

When re-loading a cubemap asset that has already been loaded once before (with the standard asset loader) it fails to load the associated texture files, leading to errors and failure to compile when applying it to the scene. The first time a cubemap is loaded however, it also loads the texture files automatically, and there's no hiccups applying it to the scene.

See this forum post for a more detailed description.

@slimbuck
Copy link
Member

Do you have a simple repro case?

Looks like there should be a very simple fix for this. On the following line:
https://github.com/playcanvas/engine/blob/main/src/framework/handlers/cubemap.js#L294

onLoad() should be calling processTexAsset() instead (since processTexAsset checks the asset is loaded before continuing).

@Astra307
Copy link
Author

Sorry I didn't make one..
Thx for fixing it anyways!!

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

Successfully merging a pull request may close this issue.

3 participants