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

Next.js Production Build - Error loading 3d tiles! Error: 3DTileLoader: unknown type #86

Open
hermanmitish opened this issue Jan 15, 2023 · 0 comments

Comments

@hermanmitish
Copy link

Hi! First of all thank you for this library!

For our project we used it with [email protected], utilizing new 'app' directory, but we tested and realized that the same issue occurs on the earlier versions of Next.js and 'pages' directory. This issue doesn't occur on the development server, but only after production build and after running it on the next production server (next build && next start).

The issue occurs when the library fails to detect 'tileset.json' as a tileset, and tries to fetch and process it as a tile (fails to correctly detect type).

The quick solution was to hardcode here instead of :
const tilesetJson = await load(url, Tiles3DLoader, { ...loadersGLOptions, });
the folowing:
const tilesetJson = await load(url, Tiles3DLoader, { ...loadersGLOptions, '3d-tiles': { isTileset: true }, });

...loadersGLOptions,

We tried to identify the root cause of such behaviour but so far failed. Is it important to leave 'isTileset' property in this place undefined, or maybe you could explicitly specify it in this line of code?

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

No branches or pull requests

1 participant