<div dir="ltr">Hi Jeremy,<div><br></div><div>><span style="font-size:12.8px">How would you do this with respect to the pager? I don't see a mechanism to inject a custom visitor to the pager to modify loaded content, ideally before caching to the file cache.</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Actually there is a way. You can use database read callback and have your visitor do stuff with the model when a tile/file is read in (paged in). Have a look at:</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">osgDB::Registry::instance()->setReadFileCallback</span><br></div><div><span style="font-size:12.8px">osgDB::Registry::ReadFileCallback</span><br></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Nick</span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Dec 14, 2015 at 3:03 PM, Jeremy <span dir="ltr"><<a href="mailto:jswigart@gmail.com" target="_blank">jswigart@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><p dir="ltr">What's the preferred method of loading a model, for example an open flight model, and pruning it of unneeded data? I assume that would be by making a custom visitor that modifies the hierarchy. Is that correct? </p>
<p dir="ltr">How would you do this with respect to the pager? I don't see a mechanism to inject a custom visitor to the pager to modify loaded content, ideally before caching to the file cache. I'm inclined to add a custom visitor pointer to the options class like a "postLoad" to post process the models in a way that is compatible with the pager and file caching. Does that seem reasonable? Did I miss any alternative methods? </p>
<br>_______________________________________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.openscenegraph.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">trajce nikolov nick<br></div>
</div>