email comments from Andew Sampson,
"I've contacted Terrex, and obtained the 2.2 version
of their trpage library. The library included a
fork of OSG 0.9.8's txp plugin, modified to load 2.1+
txp DBs.
I've done the work of incorporating the changes made
to OSG's txp plugin since 0.9.8 into Terrex's fork.
The forked version is now up-to-date with the changes
made to OSG 0.9.9 and 1.0.
Terrex made a lot of changes (especially differences
in whitespace), so the diff between the forked version
and OSG 1.0's txp plugin is yucky. I did my best, but
keep in mind that this is the result of a 4-way merge
(kinda... terrex-0.9.8, stock-0.9.8, stock-0.9.9,
stock-1.0).
I really want to see this forked version merged back
into the main OSG branch. The new features offered by
this version of the plugin (2.1+ support, variable
LOD support, bug fixes) are worth the trouble."
--
Don Tidrow then took this code and added his work.
--
Robert Osfield then fixed all the warnings that abound in the trpage code base.
discovered that TXPNodes were being culled out prematurely because the
loaded sub-tiles resulted in a computed bounds that was smaller than the
extents indicated in the archive. I think this fix should be fine. I can't
think of any reason why we would want to use anything other than the archive
extents."
get positioned correctly when the TXP database was built using the
'tile-offset' mode. I've included a tarball with what I believe are the
needed changes - they work for the sample databases I have available,
but not all conditions have been tested. I've set things up such that
these changes shouldn't affect 'normal' txp databases."
"I took a closer look at the conditional code in
SeamFinder::seamReplacement().
Because _info.minRange is a double and lod->getMinRange(0) is a float,
the difference will be calculated with double precision. If
_info.minRange is cast as a float it is exactly the same value as
lod->getMinRange(0) and the difference is exactly zero.
So if you change
if((fabs(_info.minRange-lod->getMinRange(0))<0.001)&&(fabs(_info.lod0Range-lod->getMaxRange(0))<0.001))
to
if((fabs((float)_info.minRange-lod->getMinRange(0))<0.001)&&(fabs((float)_info.lod0Range-lod->getMaxRange(0))<0.001))
it works a lot better."