Hi Torben,<br><br><div class="gmail_quote">On Fri, May 22, 2009 at 7:39 AM, Torben Dannhauer <span dir="ltr"><<a href="mailto:torben@dannhauer.info">torben@dannhauer.info</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div link="blue" vlink="purple" lang="DE">
<div>
<p><span lang="EN-US">Hello,</span></p>
<p><span lang="EN-US"> </span></p>
<p><span lang="EN-US">I discovered osgTDS for terrain modification
and have some trouble to get it working.</span></p>
<p><span lang="EN-US"> </span></p>
<p><span lang="EN-US">I got the source, compiled it and
integrated the files into my OSG installation.</span></p>
<p><span lang="EN-US">osgTDS with the example data works great
and has an impressive output.</span></p>
<p><span lang="EN-US"> </span></p>
<p><span lang="EN-US">Unfortunalety osgTDS seems not to work with
my geocentric database (WGS84) which I build with VirtualPlanetBuilder.</span></p>
<p><span lang="EN-US">During the application startup a message is
displayed, that the model is not or not completely over Terrain: “Terrain
Deformation Software: ERROR in Target Database Base definition: at
least one target is not completely over terrain.”</span></p>
</div></div></blockquote><div><br>SO you understand the historical implications, VPB is a newer product than osgTDS, and osgTDS has not been kept up with advances in osg, which would explain the difficulty you've had with integration. osgTDS is a community supported project by design, so your work with it could be valuable in keeping it up to snuff.<br>
<br>The message you are getting is undoubtedly (I haven't looked at the code for about two years), the result of your models being in a different coordinate space than the terrain over which they are positioned. I would guess that the solution is to use the same sort of coordinate node provided by OSG to position your models.<br>
<br>There may be another consideration, in that osgTDS makes some assumptions about "which way is up", or more specifically, "which is the bottom of the models", and may require some transformations to get things right.... (I'm not sure here, just guessing).<br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div link="blue" vlink="purple" lang="DE"><div><p><span lang="EN-US"></span></p>
<p><span lang="EN-US">I have read the Documentation but there are
still some beginner questions:</span></p>
<p style="margin-left: 54pt; text-indent: -18pt;"><span lang="EN-US"><span>1.<span style="font-family: "Times New Roman"; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal;">
</span></span></span><span lang="EN-US">The osgTDS loader seems to load
all targets mentioned in the .tds file by himself. Is it possible to relocate this
models in my scenery to their right place and the terrain will always be
corrected the right way?</span></p></div></div></blockquote><div>I believe that we are on the same page here regarding my first paragraph. You probably need to group your models under a coordinate system node. However, you may also need to build the support for the coordinate system node into the osgTDS traversers, as this node did not exist when osgTDS was written. <br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div link="blue" vlink="purple" lang="DE"><div><p style="margin-left: 54pt; text-indent: -18pt;">
<span lang="EN-US"></span></p>
<p style="margin-left: 54pt; text-indent: -18pt;"><span lang="EN-US"><span>2.<span style="font-family: "Times New Roman"; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal;">
</span></span></span><span lang="EN-US">How is the loading logic build?
Which model/target is parent/child of which other node, and at the end of the
loading process, which node is passed back to the application as “loaded
model” ?</span></p></div></div></blockquote><div><br>There is nothing unique about osgTDS in the file loading. it works like any other osg viewer in that all objects listed on the command line are grouped under a group node which is then formed as part of the main scene graph. This is not unique to osgTDS. The tds loader accepts a file named *.tds, then uses the information therein to find the other components, which need to preceed it on the command line. It then divides the scene graph into "Terrain" and "Targets", manipulates the coordinates of the terrain according to the position of the targets.<br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div link="blue" vlink="purple" lang="DE"><div><p style="margin-left: 54pt; text-indent: -18pt;">
<span lang="EN-US"></span></p>
<p style="margin-left: 54pt; text-indent: -18pt;"><span lang="EN-US"><span>3.<span style="font-family: "Times New Roman"; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal;">
</span></span></span><span lang="EN-US">Is there any maximum or minimum
distance up to which the terrain will be corrected to “touch” the
target?</span></p></div></div></blockquote><div>The software is designed to always connect to the target's "bottom", which is assumed to be coordinates of the "bottom hull", formed by the coords with lowest "z" value. If you want to alter the behavior, you can insert targets that are used for manipulating the terrain, but not drawn. <br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div link="blue" vlink="purple" lang="DE"><div><p style="margin-left: 54pt; text-indent: -18pt;">
<span lang="EN-US"></span></p>
<p style="margin-left: 54pt; text-indent: -18pt;"><span lang="EN-US"><span>4.<span style="font-family: "Times New Roman"; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal;">
</span></span></span><span lang="EN-US">Is it possible to use osgTDS
for loading highdetail terrainmodels into larger low-detail, and osgTDS will
adapt the low-level model that there is no z-fighting or things like that? Or is
it better to use osgEarth for that purpose?</span></p></div></div></blockquote><div>I have no idea what osgEarth is. But yes, osgTDS does, in fact, adapt the lower level model to the new set of coordinates. This allows you to shape the surface of the terrain to your liking. <br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div link="blue" vlink="purple" lang="DE"><div><p style="margin-left: 54pt; text-indent: -18pt;">
<span lang="EN-US"></span></p>
<p style="margin-left: 54pt; text-indent: -18pt;"><span lang="EN-US"><span>5.<span style="font-family: "Times New Roman"; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal;">
</span></span></span><span lang="EN-US">Is it possible to use osgTDS in
combination with osgEarth? Both projects seem to use a loader-plugin over
osgDB.</span></p></div></div></blockquote><div><br>Again, I have no idea what osgEarth is. osgDB and "loader-plugin" however are not mutually exclusive. osgDB is the framework by which osgTDS and other plugins work.<br>
<br>-don <br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div link="blue" vlink="purple" lang="DE"><div><p style="margin-left: 54pt; text-indent: -18pt;">
<span lang="EN-US"></span></p>
<p style="margin-left: 54pt;"><span lang="EN-US"> </span></p>
<p><span lang="EN-US">Thanks for your help,</span></p>
<p><span lang="EN-US"> </span></p>
<p><span lang="EN-US">Torben</span></p>
<p><span lang="EN-US"> </span></p>
</div>
</div>
<br>_______________________________________________<br>
osg-tds mailing list<br>
<a href="mailto:osg-tds@andesengineering.com">osg-tds@andesengineering.com</a><br>
<a href="http://andesengineering.com/mailman/listinfo/osg-tds" target="_blank">http://andesengineering.com/mailman/listinfo/osg-tds</a><br>
<br></blockquote></div><br>