<div dir="ltr">Hi Werner, <div><br></div><div>I think you may try using osg::Registry::instance()->addReaderWriter( YourReaderWriterInstance ) to add your own localy defined RW. Your RW will need to override supportedExtensions() and/or acceptsExtension() virtual methods. But I guess you must have already done that....</div><div><br></div><div>Cheers,</div><div>Wojtek</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-11-16 16:51 GMT+01:00 Werner Modenbach <span dir="ltr"><<a href="mailto:Werner.Modenbach@texion.eu" target="_blank">Werner.Modenbach@texion.eu</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Hi Robert,<br>
<br>
I think I have all the coding done and in my opinion it should
work.<br>
But it doesn't and I figured out why.<br>
When using osgDB with my own ReaderWriter it automatically uses the<br>
dynamic load feature and the ReaderWriter is expected to be a dll in
the plugins folder.<br>
Unfortunately my ReaderWriter is very much depending on many classes
I have in my <br>
project and also has dependencies to Qt.<br>
Creating such a dll would be a complete overkill of link
dependencies.<br>
Is there any way avoiding the dynamic load mechanism and using an
instance of a<br>
class being part of my static libs?<br>
<br>
Thanks in advance for any hints.<span class=""><br>
<br>
- Werner -<br>
<br>
<div class="m_-490554052358015306moz-cite-prefix">Am 11.11.2016 um 12:47 schrieb Robert
Osfield:<br>
</div>
</span><div><div class="h5"><blockquote type="cite">
<pre>Hi Wener,
On 11 November 2016 at 11:32, Werner Modenbach
<a class="m_-490554052358015306moz-txt-link-rfc2396E" href="mailto:Werner.Modenbach@texion.eu" target="_blank"><Werner.Modenbach@texion.eu></a> wrote:
</pre>
<blockquote type="cite">
<pre>just one more small question.
As to my understanding the ReaderWriter classes are instantiated
automatically
according to the "file extensions". So I get no hands on the instances of
the reader.
How can I give the reader class a reference to my data structures?
</pre>
</blockquote>
<pre>You can pass data into a plugin via the osgDB::Options object that you
can pass along with the string used for the filename. The Options
object can store user data as well be subclassed.
Robert.
______________________________<wbr>_________________
osg-users mailing list
<a class="m_-490554052358015306moz-txt-link-abbreviated" href="mailto:osg-users@lists.openscenegraph.org" target="_blank">osg-users@lists.<wbr>openscenegraph.org</a>
<a class="m_-490554052358015306moz-txt-link-freetext" href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" target="_blank">http://lists.openscenegraph.<wbr>org/listinfo.cgi/osg-users-<wbr>openscenegraph.org</a>
</pre>
</blockquote>
<br>
</div></div><span class=""><div class="m_-490554052358015306moz-signature">-- <br>
<b>TE<span style="color:red">X</span>ION Software Solutions</b>,
Rotter Bruch 26a, D-52068 Aachen<br>
Phone: +49 241 475757-0<br>
Fax: <a href="tel:%2B49%20241%20475757-29" value="+4924147575729" target="_blank">+49 241 475757-29</a><br>
Web: <a class="m_-490554052358015306moz-txt-link-freetext" href="http://texion.eu" target="_blank">http://texion.eu</a><br>
eMail: <a class="m_-490554052358015306moz-txt-link-abbreviated" href="mailto:info@texion.eu" target="_blank">info@texion.eu</a></div>
</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>