[osg-users] Dynamical loading of resources

Robert Osfield robert.osfield at gmail.com
Tue Aug 22 06:27:52 PDT 2017

Hi Joachim,

On 22 August 2017 at 14:05, Joachim Gehrung <
joachim.gehrung at iosb.fraunhofer.de> wrote:

> sorry for my late reply. One of my requirements is that the backend should
> be flexible... this was why is was so attached to the DatabasePager when I
> first heared about it ;). To me it sounded like the part one needs to
> exchange to switch backends. Well, if it isn't the DatabasePager, what is
> it then? As far as I were able to follow your suggestions, I may need
> different PagedLODs or some kind of plugin you mentioned, but I don't know
> about already, correct :)?

I think you mis-understood the role of the DatabasePager - it's the tool
that the manages the theading or loading, compile, merging and expiring
subgraphs, it doesn't do any loading itself, it defers all the loading to
the standard osgDB file loading mechniams managed by the osgDB::Registry.

To do different backends all you need is different plugins that do the
loading for you.

> A possible "backend" is of course the file system, but it should also be
> possible to handle a server with a proprietary protocol.

Have a look at the curl plugin that provides the OSG's support for
http/https loading of data.  This takes filenames as input and opens up a
connection using libcurl and then uses other OSG plugins to load the actual

The curl plugin doesn't actually know anything about the DatabasePager and
the DatabasePager knows nothing about the curl plugin as the two are
completely independent yet work really well together.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20170822/f567ebfa/attachment.htm>

More information about the osg-users mailing list