Rendering OBJ/MTL breaks when texture image is NPOT
See original GitHub issueHere’s the code: https://github.com/abdielou/npot-bug-demo
When rendering models with NPOT texture images, the app breaks with the following stack trace:
Can't find variable: HTMLImageElement
makePowerOfTwo
uploadTexture three.js:18101:25
setTexture2D
setTexture2D
setValueT1 three.js:4971:2
...
Version:
"dependencies": {
"expo": "^25.0.0",
"expo-graphics": "^0.0.3",
"expo-three": "^2.2.2-alpha.1",
"react": "16.2.0",
"react-native": "0.52.0",
"three": "^0.90.0"
}
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Importing OBJ with MTL and Image not working properly
1. Check the obj file. In your case the obj is not exported correctly. Obj is a human readable file format it is...
Read more >html - .mtl file not rendering properly - Stack Overflow
I have .obj file and .mtl file and I'm trying to render those file using THREE.JS. But obj was loaded but colors and...
Read more >When I import a .obj from formit into a renderer, some texture ...
Solved: When I import a .obj from formit into a renderer, some texture are broken. How to solve this problem.
Read more >MTL file in Rhino - Rendering - McNeel Forum
How to render the .obj file with .mtl(or as in the picture) ... If you have a model that is not coming over...
Read more >usdz texture issue (using usdz_converter) - Apple Developer
It might be the usdz_converter itself is still kind of buggy? Some OBJ just does not convert to proper USDZ with texture. I...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I think this might be an android bug, will test and get back to you.
I fixed this in
@expo/browser-polyfill
should work for you now