viewer#1730 Crash in LLFetchedGLTFMaterial::bind

master
Andrey Kleshchev 2024-06-12 11:21:15 +03:00 committed by Andrey Kleshchev
parent f1a756bd76
commit 718189085a
1 changed files with 5 additions and 2 deletions

View File

@ -756,9 +756,12 @@ void LLRenderPass::pushGLTFBatch(LLDrawInfo& params)
{
auto& mat = params.mGLTFMaterial;
mat->bind(params.mTexture);
if (mat.notNull())
{
mat->bind(params.mTexture);
}
LLGLDisable cull_face(mat->mDoubleSided ? GL_CULL_FACE : 0);
LLGLDisable cull_face(mat.notNull() && mat->mDoubleSided ? GL_CULL_FACE : 0);
setup_texture_matrix(params);