<div dir="ltr">would that not just replicate the osg filecache? readNode should just return the pointer to the data with readResult FILE_LOADED_FROM_CACHE<div>regards, Laurens.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Nov 29, 2016 at 1:56 PM, Trajce Nikolov NICK <span dir="ltr"><<a href="mailto:trajce.nikolov.nick@gmail.com" target="_blank">trajce.nikolov.nick@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Simone,<div><br></div><div>just a fast thought ... Maybe you make a simple std::map to keep track of what has been loaded and what is new</div></div><div class="gmail_extra"><div><div class="h5"><br><div class="gmail_quote">On Tue, Nov 29, 2016 at 1:37 PM, Simone Rapposelli <span dir="ltr"><<a href="mailto:simone.rapposelli@gmail.com" target="_blank">simone.rapposelli@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Robert,<br>
<br>
thank you for your fast reply.<br>
My problem is that osgDB::ReaderWriter::ReadResul<wbr>t readNode(const std::string &fileName, const osgDB::ReaderWriter::Options *options) gets called even if a PagedLod with the same fileName has been previously loaded: for example, this happens if I move to any position on the viewer and then come back.<br>
Thus, inside this function I need to check if any of the PagedLod currently loaded in DatabasePager has the same fileName of the passed argument: in this case I could avoid to reload data already in memory.<br>
<span><br>
Thank you!<br>
<br>
Cheers,<br>
Simone<br>
<br>
------------------<br>
Read this topic online here:<br>
</span><a href="http://forum.openscenegraph.org/viewtopic.php?p=69524#69524" rel="noreferrer" target="_blank">http://forum.openscenegraph.or<wbr>g/viewtopic.php?p=69524#69524</a><br>
<div class="m_371709416000233654HOEnZb"><div class="m_371709416000233654h5"><br>
<br>
<br>
<br>
<br>
______________________________<wbr>_________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org" target="_blank">osg-users@lists.openscenegraph<wbr>.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.or<wbr>g/listinfo.cgi/osg-users-opens<wbr>cenegraph.org</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div></div></div><span class="HOEnZb"><font color="#888888">-- <br><div class="m_371709416000233654gmail_signature" data-smartmail="gmail_signature">trajce nikolov nick<br></div>
</font></span></div>
<br>______________________________<wbr>_________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.<wbr>openscenegraph.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.<wbr>org/listinfo.cgi/osg-users-<wbr>openscenegraph.org</a><br>
<br></blockquote></div><br></div>