Hi Robert -- If you will accept my submission for the FSTV issue, then
that still leaves the problem with MERGE_GEODES. For your convenience,
I'm attaching a small OSG file designed to trigger this specific problem.
I understand that the LessGeode struct is intended to group Geodes
together by NodeMask, so that only Geodes with the same NodeMask are
merged. But there doesn't appear to be a mechanism in place to prevent
the Optimizer from trying to merge a Geode with itself, which is what
happens with the attached file.
When the code does a push_back of a Geode onto the
geodeDuplicateMap::second (std::list of Geode*), one solution would be
to replace that with a std::set of Geode* so that only unique addresses
end up in the list. But std::set of course doesn't support push_back.
Rather than perform major surgery without you looking on, I thought I'd
wait for your input before attempting a fix.
Thanks,
-Paul
Group {
name "The top Group"
nodeMask 0xffffffff
cullingActive TRUE
num_children 2
Geode {
UniqueID Geode_1
nodeMask 0xffffffff
cullingActive TRUE
num_drawables 1
Geometry {
DataVariance STATIC
useDisplayList TRUE
useVertexBufferObjects FALSE
PrimitiveSets 1
{
DrawElementsUShort TRIANGLE_STRIP 4
{
0 1 2 3
}
}
VertexArray Vec3Array 4
{
0 0 0
1 0 0
0 0 1
1 0 1
}
ColorBinding OVERALL
ColorArray Vec4Array 1
{
1 1 1 1
}
}
}
Use Geode_1
}
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org