Closed amin2312 closed 2 years ago
It supports both WebGL1 and WebGL2
Does it output nothing or is the model rendered just black?, Which device are you using?
The model rendered just black. I use Redmi 5A and Galaxy Grand Prime, them only support WebGL1.
Could you please test and turn off lighting and see if the colors are being rendered?
model.meshes[0].material.unlit = true
Could you also please visit https://webglreport.com with that device and post the results if possible?
Could you please test and turn off lighting and see if the colors are being rendered?
model.meshes[0].material.unlit = true
Yes, use this option, the render is normal
Could you also please visit https://webglreport.com with that device and post the results if possible?
Thanks a lot, I'll try to make something out of this info.
I tested on an old device "Samsung Galaxy Core Prime" which seems pretty similar to yours, it was release 2014. First I had issues, but after upgrading to latest Chrome all the examples looked correct.
Just to make sure, could please see if you have latest Chrome installed and try again?
Is this phone support WebGL2? If the device can't support WebGL2, it can't run it normally, even if use the new chrome versoin. I have tested 3 old phone(don't support WebGL2), all aren't normal.
Yes it does support WebGL 2, but that is not why it works. I can force PixiJS to use WebGL 1 by doing PIXI.settings.PREFER_ENV = PIXI.ENV.WEBGL
and it still works on my Galaxy Core Prime.
I also know that the library works on WebGL 1, because everything is correct on iPhone/Safari (and no iPhone supports WebGL 2). It just has to be something else, which I'm trying to figure out. Which is the third device you have tested this on? (I already know you have Galaxy Grand Prime and Redmi 5A). I would need one of those phone for testing, but it seems they are hard to get.
Does the lighting example https://github.com/jnsmalm/pixi3d/blob/develop/examples/src/lighting.js work on any of your Android devices?
Hello! I faced a similar problem. My 3D-model does not displayed on ios10-13 at all, but on ios14 and android 7- 11 it works correctly. How can this be fixed?
Hello! I faced a similar problem. My 3D-model does not displayed on ios10-13 at all, but on ios14 and android 7- 11 it works correctly. How can this be fixed?
Hi!
model.meshes.forEach(mesh => mesh.material.unlit = true)
I don't have a iOS device < 14 so I can't test for myself.
Hello! I faced a similar problem. My 3D-model does not displayed on ios10-13 at all, but on ios14 and android 7- 11 it works correctly. How can this be fixed?
Hi!
- Is the model rendered black or is it not displayed at all?
- If you connect your device to a desktop machine and debug it, do you get any errors or warnings in console?
- Does any of the examples (included in repo) work correctly?
- Have you tried turning off lighting calculations?
model.meshes.forEach(mesh => mesh.material.unlit = true)
I don't have a iOS device < 14 so I can't test for myself.
Hello! Thank you! The model did not displayed at all. The problem connected with function Uint8Array.from(), using Babel's polyfill package didn't help for me. I rewrote the function to 'new Uint8Array()' and it is working good now.
@kasiaustas Good to know! Did you change it in src/gltf/gltf-asset.ts file only? So I can apply this update, or maybe you can submit a PR?
@kasiaustas Good to know! Did you change it in src/gltf/gltf-asset.ts file only? So I can apply this update, or maybe you can submit a PR?
Perhaps this is related to this
PIXI3D.ShadowCastingLight.isMediumQualitySupported(app.renderer)
@kasiaustas Good to know! Did you change it in src/gltf/gltf-asset.ts file only? So I can apply this update, or maybe you can submit a PR?
Perhaps this is related to this
PIXI3D.ShadowCastingLight.isMediumQualitySupported(app.renderer)
I guess he is referring to https://github.com/jnsmalm/pixi3d/blob/develop/src/gltf/gltf-asset.ts#L126, it's the only place in code where Uint8Array.from()
is used.
As this library is now being used in production in different projects with hundres of thousand of users I have not received any indication this is a real problem. Users seem to simply not use these devices which have these issues or the number of users with those devices is so small that it's simply not worth the effort fixing this. If anyone can provide me devices which have these issues (so I can debug this), let me know.
I found that if the device can't support WebGL2, it can't be displayed. Is it right? This library is only run in WebGL2?