Closed guazipi closed 8 years ago
Can you share the original OBJ model so we can debug this?
Thanks for sending over the model. The problem was caused by the formatting of the obj file, in particular your file defines faces like f 596/596/ 688/688/ 2116/2116/
whereas the code expected f 596/596 688/688 2116/2116
. I made a quick change to support that formatting, and tested that it loads without errors in Cesium.
Thank you very much, I'm glad to hear that. You mean I have to change the file like f 596/596/ 688/688/ 2116/2116/ to f 596/596 688/688 2116/2116 one by one? Oh, that's a terrible news. I'll try it right now, thank you again!
I made a change to the code to support the formatting, just download it again and test it out. You don't need to do it by hand.
awesome,I've tested it and it ran in Cesium without errors, but I have another problem which is that texture isn't on his position. Is your texture on the right position when you tested it?
It should be like this:
Look forward to your reply!
I'm not completely sure why this is happening, but one temporary fix is to flip the image vertically. It looks correct to me now:
Can you share the code to me? Thank you very much
I just flipped the image in Paint. Once again, its a temporary fix and I hope to find the real problem.
Actually, I don't understand what you said about flipped the image, how did you operate the texture of gltf model?
Hi, Sean, I am here again. Sorry to disturb you again, but I still get it about 'flip the image', I just don't understand how you can operate the texture of model. I add the model as an entity on the Cesium, Please help me to figure it out and show me how to do it, thank you very much, look forward to your reply!
Sorry for the delay. What I mean about flipping the image is doing it in some outside program, you shouldn't have to make any changes in Cesium or the glTF model. If you use this image here it should work for you as well.
I've convert my obj file to gltf, when I added gltf on the cesium, an error happened, just as follows: I don't know why. Please help me