Earlier this week I bought a new computer. Apparently, there’s a gpu shortage so I did some musical chairs with my gpu’s. My previous computer, with my panda3D projects on it, now has a Nvidia GTX 1070 gpu installed. Official Nvidia driver, the most recent one.
I did not make any changes to the code, but now the graphics are foobed. If all goes well there should be a partial screenshot included with this post. I’m using the free Kenny’s space assets pack for my models. The project had/has working shadows, an orthographic lens for the camera, directional lighting and ambient lighting. That should all still be there, I might have accidently broken something by poking around to try and fix it.
The models were converted from gtf to bam, I rebammed one as a test, that didnt change anything. In case it matters, here’s the code/command line used to convert them:
gltf2bam GLTFformat/craft_miner.glb GLTF2BAM/craft_miner.bam
The partial circle at the bottom left is a collisionSphere I’m using to mark 0,0,0 in the scene.
Odd that the change of graphics card had this effect. I also used a GeForce 1070 until recently, without much issue.
Are you using simplepbr? And are you using the latest version of panda3d-gltf? Does the model appear correctly in the gltf-viewer shipped with panda3d-gltf?
What happens if you run an OpenGL test, or another game that uses 3D acceleration? Are there problems with any such?
If not, what happens if you load your models in PView?
Graphics are normal in other games (Factorio, Killing Floor 2). I’ve narrowed it down to the shader. The lighting and such works, it’s the render.setShaderAuto() that turns everything black.
I went into the config.prc file in the etc folder and changed it to:
Now everything works, including the AutoShader and the shadows. I guess something went wrong when installing the drivers. It’s possible that the other applications were set to using directx, thus hiding the problem. Now that it has been narrowed down, I’m going to reinstall the drivers and see if that helps. It does not appear to be a Panda3D issue, and even if I cant fix it for whatever reason, I can just keep using the pandadx9, so consider this problem resolved.
Thank you for the help.