<div dir="ltr"><div>Hello Robert,</div><div><br></div><div>to test it with my old osg version, i fixed the obj file such it does not contain any indices to normals anymore, as there are no normals.</div><div>This indeed helped loading the model, but no textures appear at all. Should it load the textures automatically due to the first line in the obj file being mtllib Data.mtl and the use of usemtl material_0 before the faces or do i need to take extra care when loading a textured model?</div><div><br></div><div>For loading, im using only:</div><div><br></div><div><pre lang="cpp"><span lang="cpp"><span>osgDB</span><span>::</span><span>Options</span><span>*</span> <span>opt</span> <span>=</span> <span>new</span> <span>osgDB</span><span>::</span><span>Options</span><span>;</span></span>
<span lang="cpp"><span>opt</span><span>-></span><span>setOptionString</span><span>(</span><span>"<wbr>noRotation"</span><span>);</span></span>
<span lang="cpp"></span>
<span lang="cpp"><span>osg</span><span>::</span><span>ref_ptr</span><span><</span><span>osg</span><span>::</span><span>Node</span><span>></span> <span>node</span> <span>=</span> <span>osgDB</span><span>::</span><span>readNodeFile</span><span>(<wbr>pathToObjFile</span><span>,</span> <span>opt</span><span>);</span></span></pre></div><div><br></div><div>Best,</div><div>Tom<br></div><div><br></div><div><img src="cid:autoGeneratedInlineImage1" alt="" style="" width="320" height="148"></div><br>Am Dienstag, 14. Januar 2020 17:25:27 UTC+1 schrieb Robert Osfield:<blockquote class="gmail_quote" style="margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;"><div dir="ltr"><div dir="ltr">On Tue, 14 Jan 2020 at 15:26, 'Tom Pollok' via OpenSceneGraph Users <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="N6DBZVhsCAAJ" rel="nofollow" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">osg-...@googlegroups.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Thank you for the workaround.</div><div><br></div><div>So as far as i understand you only add the texture coordinate and normal, if there exists one with a index greater than 0 and less then the number of normals or texture coordinates.</div><div>So that means that openscenegraph now will be able to display the textured mesh, even if the normals are missing, right?<br></div></div></blockquote><div><br></div><div>Yes, that's correct, you'll get a textured mesh with no normals assigned.</div><div><br></div><div>Robert.<br></div><div> </div></div></div>
</blockquote></div>

<p></p>

-- <br />
You received this message because you are subscribed to the Google Groups "OpenSceneGraph Users" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="mailto:osg-users+unsubscribe@googlegroups.com">osg-users+unsubscribe@googlegroups.com</a>.<br />
To view this discussion on the web visit <a href="https://groups.google.com/d/msgid/osg-users/b55a82c5-4801-49da-b1c4-149d868bd6fa%40googlegroups.com?utm_medium=email&utm_source=footer">https://groups.google.com/d/msgid/osg-users/b55a82c5-4801-49da-b1c4-149d868bd6fa%40googlegroups.com</a>.<br />