WS30: Add zUpTransform and modelOffset Uniforms.

This commit is contained in:
Stuart Buchanan 2021-11-19 22:05:47 +00:00
parent 6562546771
commit fee4481ef6

View File

@ -1382,6 +1382,8 @@ void VPBTechnique::applyColorLayers(BufferData& buffer, Locator* masterLocator)
stateset->addUniform(atlas.ambient); stateset->addUniform(atlas.ambient);
stateset->addUniform(atlas.diffuse); stateset->addUniform(atlas.diffuse);
stateset->addUniform(atlas.specular); 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()));
} }
} }