diff --git a/components/nifosg/nifloader.cpp b/components/nifosg/nifloader.cpp index f8ee15062..9fbee3d4d 100644 --- a/components/nifosg/nifloader.cpp +++ b/components/nifosg/nifloader.cpp @@ -1230,6 +1230,7 @@ namespace NifOsg case Nif::NiTexturingProperty::BaseTexture: case Nif::NiTexturingProperty::GlowTexture: case Nif::NiTexturingProperty::DarkTexture: + case Nif::NiTexturingProperty::BumpTexture: case Nif::NiTexturingProperty::DetailTexture: break; case Nif::NiTexturingProperty::GlossTexture: @@ -1237,11 +1238,6 @@ namespace NifOsg std::cerr << "NiTexturingProperty::GlossTexture in " << mFilename << " not currently used." << std::endl; continue; } - case Nif::NiTexturingProperty::BumpTexture: - { - std::cerr << "NiTexturingProperty::BumpTexture in " << mFilename << " not currently used." << std::endl; - continue; - } case Nif::NiTexturingProperty::DecalTexture: { std::cerr << "NiTexturingProperty::DecalTexture in " << mFilename << " not currently used." << std::endl; @@ -1315,6 +1311,11 @@ namespace NifOsg texEnv->setSource1_RGB(GL_TEXTURE); stateset->setTextureAttributeAndModes(texUnit, texEnv, osg::StateAttribute::ON); } + else if (i == Nif::NiTexturingProperty::BumpTexture) + { + // Set this texture to Off by default since we can't render it with the fixed-function pipeline + stateset->setTextureMode(texUnit, GL_TEXTURE_2D, osg::StateAttribute::OFF); + } switch (i) {