diff --git a/simgear/scene/tgdb/VPBTechnique.cxx b/simgear/scene/tgdb/VPBTechnique.cxx index d5fcc2be..74e59d56 100644 --- a/simgear/scene/tgdb/VPBTechnique.cxx +++ b/simgear/scene/tgdb/VPBTechnique.cxx @@ -1382,6 +1382,8 @@ void VPBTechnique::applyColorLayers(BufferData& buffer, Locator* masterLocator) stateset->addUniform(atlas.ambient); stateset->addUniform(atlas.diffuse); stateset->addUniform(atlas.specular); + stateset->addUniform(new osg::Uniform("zUpTransform", osg::Matrixf(osg::Matrix::inverse(makeZUpFrameRelative(loc))))); + stateset->addUniform(new osg::Uniform("modelOffset", buffer._transform->getMatrix().getTrans())); } }