Hi Chris -- Thanks for this work! This will be a handy tool. I've been
wishing for something like this for some time now.
I've added your patches to my local OSG tree and tested your changes
with a ProxyNode-based database, which I mailed you a copy of offline.
All worked well, with the following notes:
1) I had to use a .ive option to prevent autoloading the ProxyNodes, so
my command line looked like:
osgconv -O noLoadExternalReferenceFiles -R .ive USMC23_4009.ASM.ive
master.ive
If I left off the "-O noLoadExternalReferenceFiles", then I got only one
output file, and it was huge -- contained all the loaded data from the
ProxyNodes. You might think of this as a future.
2) I understand that you strip ALL extensions in order to support the
pseudoloaders. But note that the files in my example database just
happen to be named with two extensions: "USMC23_4117.PRT.ive" for
example. Your code outputs this as "USMC23_4117.osg" when converted to
.OSG format. This is probably OK; I'm probably one of few people with a
bunch of Pro/E part and assembly files that I'm rendering in OSG>
Aside from those two notes, things worked as expected. Robert will need
to review and commit.
Paul Martz
Skew Matrix Software LLC
_http://www.skew-matrix.com_ <http://www.skew-matrix.com/>
+1 303 859 9466
Chris 'Xenon' Hanson wrote:
This patch is dependent on virtually every other patch I already submitted
today.
The included changes add a new option to osgconv, "-R [suffix]" to permit
batch
recursive conversion of databases with external references via PagedLOD or
ProxyNode
objects. This is mainly intended for and tested with terrain databases built by
VirtualPlanetBuilder's osgdem tool.
The suffix is optional, but may be used to propagate a format change. Without
a
specified suffix, osgconv will simply rewrite PagedLOD/ProxyNode child output
files to the
same location as the main output file specified on the command-line, using the
same name
and format as they originally were. If you are employing osgconv to convert
from .osg to
.ive (or reverse), this means the top-level file will be written to the new
format, but
the child files will remain in their original format. Therefore, when
converting the
top-level file from .osg to .ive, you need to specify
-R .ive
The suffix-handling code will strip off ALL suffixes from the child filenames
before
adding the new suffix. This means if you are employing a pseudo-loader
technique (an input
filename ending in something like ".osg.scale") the pseudo-loader suffix will
be properly
removed prior to constructing the output filename. In this case you might even
have an
input file like ".osg.scale" and an output suffix of "-R .osg" which would not
convert
formats, but simply apply and strip off the pseudo-loader.
i have tested all of these features with VPB/osgdem terrain databases, but do
not have
any way to test them with ProxyNode.
Once this code is in trunk, I will update the osgconv wiki page to reflect
this new
functionality.
------------------------------------------------------------------------
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org