<div dir="ltr"><div><div><div><br></div><br></div><div>Could this be caused by a static osg::Image() object (or another static object that creates the osg::Image in its constructor) that's getting initialized before the program's main() function is even called? This is too early, as OSG plugins would not be registered at that point. It might work with a fully static OSG build (including the JPEG plugin)<br></div><br></div>Christian<br><br></div><div class="gmail_extra"><br><div class="gmail_quote">2017-11-06 9:42 GMT+01:00 Robert Osfield <span dir="ltr"><<a href="mailto:robert.osfield@gmail.com" target="_blank">robert.osfield@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Rômulo,<br>
<br>
I have had a look at the debug output and the error message is being<br>
reported prior to any of the OSG messages. I had done a search for the<br>
warning string in the OSG using:<br>
<br>
<br>
    cd OpenSceneGraph<br>
    grep -r "Warning: Error in reading to" .<br>
<br>
<br>
But don't get any hits.  It looks to me like the OSG isn't coming from<br>
the OSG side.<br>
<br>
Robert.<br>
<br>
On 4 November 2017 at 22:37, Rômulo Cerqueira<br>
<div class="HOEnZb"><div class="h5"><<a href="mailto:romulogcerqueira@gmail.com">romulogcerqueira@gmail.com</a>> wrote:<br>
> Hi community!<br>
><br>
> I got some problems by loading JPG images using OSG.<br>
><br>
> When I read them directly using osgviewer, the images are loaded with success.<br>
><br>
><br>
> Code:<br>
><br>
> osgviewer --image /home/romulo/gray_texture_n.<wbr>jpg<br>
><br>
><br>
><br>
><br>
> However, the problem occurs when I read the images by OSG code, as presented in my unitary test code: <a href="https://github.com/Brazilian-Institute-of-Robotics/simulation-normal_depth_map/blob/master/test/NormalMapping_test.cpp" rel="noreferrer" target="_blank">https://github.com/Brazilian-<wbr>Institute-of-Robotics/<wbr>simulation-normal_depth_map/<wbr>blob/master/test/<wbr>NormalMapping_test.cpp</a><br>
><br>
> I got the following output message:<br>
><br>
> Code:<br>
><br>
> Warning: Error in reading to "/home/romulo/gray_texture_n.<wbr>jpg".<br>
><br>
><br>
><br>
><br>
> How can I fix this? I will appreciate any information or help on the same.<br>
><br>
> Cheers,<br>
> Rômulo[/code][/b]<br>
><br>
> ------------------<br>
> Read this topic online here:<br>
> <a href="http://forum.openscenegraph.org/viewtopic.php?p=72307#72307" rel="noreferrer" target="_blank">http://forum.openscenegraph.<wbr>org/viewtopic.php?p=72307#<wbr>72307</a><br>
><br>
><br>
><br>
><br>
> Attachments:<br>
> <a href="http://forum.openscenegraph.org//files/screenshot_from_2017_11_04_19_31_10_130.png" rel="noreferrer" target="_blank">http://forum.openscenegraph.<wbr>org//files/screenshot_from_<wbr>2017_11_04_19_31_10_130.png</a><br>
><br>
><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>
______________________________<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>
</div></div></blockquote></div><br></div>