Merge branch 'master' into text_improvements
This commit is contained in:
@@ -517,9 +517,10 @@ void Program::apply( osg::State& state ) const
|
||||
// for shader debugging: to minimize performance impact,
|
||||
// optionally validate based on notify level.
|
||||
// TODO: enable this using notify level, or perhaps its own getenv()?
|
||||
#ifndef __APPLE__
|
||||
if( osg::isNotifyEnabled(osg::INFO) )
|
||||
pcp->validateProgram();
|
||||
|
||||
#endif
|
||||
pcp->useProgram();
|
||||
state.setLastAppliedProgramObject(pcp);
|
||||
}
|
||||
|
||||
@@ -136,9 +136,6 @@ bool RigTransformHardware::createPalette(int nbVertexes, BoneMap boneMap, const
|
||||
OSG_INFO << "RigTransformHardware::createPalette will use " << boneNameCountMap.size() * 4 << " uniforms" << std::endl;
|
||||
|
||||
|
||||
for (int i = 0 ; i < (int)vertexIndexWeight.size(); i++)
|
||||
vertexIndexWeight[i].resize(maxBonePerVertex);
|
||||
|
||||
_nbVertexes = nbVertexes;
|
||||
_bonesPerVertex = maxBonePerVertex;
|
||||
_bonePalette = palette;
|
||||
@@ -181,7 +178,7 @@ RigTransformHardware::BoneWeightAttribList RigTransformHardware::createVertexAtt
|
||||
int boneIndexInVec4 = b*2;
|
||||
(*array)[j][0 + boneIndexInVec4] = 0;
|
||||
(*array)[j][1 + boneIndexInVec4] = 0;
|
||||
if (boneIndexInList < getNumBonesPerVertex())
|
||||
if (boneIndexInList < _vertexIndexMatrixWeightList[j].size())
|
||||
{
|
||||
float boneIndex = static_cast<float>(_vertexIndexMatrixWeightList[j][boneIndexInList].getIndex());
|
||||
float boneWeight = _vertexIndexMatrixWeightList[j][boneIndexInList].getWeight();
|
||||
|
||||
@@ -438,9 +438,11 @@ void Text3D::computeGlyphRepresentation()
|
||||
{
|
||||
(*_coords)[i] += position;
|
||||
}
|
||||
_coords->dirty();
|
||||
|
||||
// copy normals
|
||||
_normals->insert(_normals->end(), src_normals->begin(), src_normals->end());
|
||||
_normals->dirty();
|
||||
|
||||
copyAndOffsetPrimitiveSets(_frontPrimitiveSetList, it->_glyphGeometry->getFrontPrimitiveSetList(), base);
|
||||
copyAndOffsetPrimitiveSets(_wallPrimitiveSetList, it->_glyphGeometry->getWallPrimitiveSetList(), base);
|
||||
|
||||
@@ -500,7 +500,7 @@ void LineSegmentIntersector::intersect(osgUtil::IntersectionVisitor& iv, osg::Dr
|
||||
if (reachedLimit()) return;
|
||||
|
||||
osg::Vec3d s(_start), e(_end);
|
||||
if ( !intersectAndClip( s, e, drawable->getBoundingBox() ) ) return;
|
||||
if ( drawable->isCullingActive() && !intersectAndClip( s, e, drawable->getBoundingBox() ) ) return;
|
||||
|
||||
if (iv.getDoDummyTraversal()) return;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user