UnityGLTF icon indicating copy to clipboard operation
UnityGLTF copied to clipboard

Textures not exported in .glb

Open KasperKronborgUnity opened this issue 5 years ago • 3 comments

When exporting .glb models using SaveGLBToStream(Stream stream, string sceneName) and SaveGLBToByteArray(string sceneName) textures are not included in the .glb file.

Including this line as the first in SaveGLBToStream() seems to fix it, but I have not tested it much.

_shouldUseInternalBufferForImages = true;

KasperKronborgUnity avatar Feb 06 '20 14:02 KasperKronborgUnity

Has this been resolved? Found the same issue.

jaspreetdhanjan avatar Aug 23 '20 22:08 jaspreetdhanjan

I used the PBR Metallic Roughness shader for the material and it fixed it.

jaspreetdhanjan avatar Aug 24 '20 00:08 jaspreetdhanjan

I used the PBR Metallic Roughness shader for the material and it fixed it.

Can you elaborate? I can't find either a "_shouldUseInternalBufferForImages" anywhere, nor anything changed when I added the PBR shader in the material.

marioslokas-v avatar Feb 19 '21 12:02 marioslokas-v

Please update to the latest version and open a new issue if the problem persists. Thanks!

pfcDorn avatar Feb 09 '24 08:02 pfcDorn