Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-15 Thread 'Tom Pollok' via OpenSceneGraph Users
Hi Laurens,

thank you for clarification! My problem was that im using openscenegraph in 
combination with osgEarth. I figured out how to fix it, so in case other 
osg and osgEarth users might run into the same issue.

To fix the issue i had to include

#include 

and after loading the model i had to run the shader generator on the model.

osgEarth::Registry::shaderGenerator().run( model );

Now everything works fine.

Thank you very much for your super quick help @Laurens and @Robert !!!

Best,
Tom

Am Mittwoch, 15. Januar 2020 13:00:41 UTC+1 schrieb Voerman, L.:
>
> Hi Tom,
> Your model works with texture for me, in osg 3.4.0 as well as 3.6.5 with 
> the following commands:
> sed -E "s#(f [0-9]+/[0-9]+)/0 ([0-9]+/[0-9]+)/0 ([0-9]+/[0-9]+)/0#\1 \2 
> \3#" "Data2.obj" > noNormals.obj
> osgviewer -O noRotation  noNormals.obj 
> Laurens.
>
>
> On Wed, Jan 15, 2020 at 12:24 PM 'Tom Pollok' via OpenSceneGraph Users <
> osg-...@googlegroups.com > wrote:
>
>> Hello Robert,
>>
>> 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.
>> 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?
>>
>> For loading, im using only:
>>
>> osgDB::Options* opt = new 
>> osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr 
>> node = osgDB::readNodeFile(pathToObjFile, opt);
>>
>>
>> Best,
>> Tom
>>
>>
>> Am Dienstag, 14. Januar 2020 17:25:27 UTC+1 schrieb Robert Osfield:
>>>
>>> On Tue, 14 Jan 2020 at 15:26, 'Tom Pollok' via OpenSceneGraph Users <
>>> osg-...@googlegroups.com> wrote:
>>>
 Thank you for the workaround.

 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.
 So that means that openscenegraph now will be able to display the 
 textured mesh, even if the normals are missing, right?

>>>
>>> Yes, that's correct, you'll get a textured mesh with no normals assigned.
>>>
>>> Robert.
>>>  
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "OpenSceneGraph Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to osg-...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/osg-users/b55a82c5-4801-49da-b1c4-149d868bd6fa%40googlegroups.com
>>  
>> 
>> .
>> ___
>> osg-users mailing list
>> osg-...@lists.openscenegraph.org 
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/79d8878f-0123-4a3a-8d70-1e2e3eb9e20c%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-15 Thread Voerman, L.
Hi Tom,
Your model works with texture for me, in osg 3.4.0 as well as 3.6.5 with
the following commands:
sed -E "s#(f [0-9]+/[0-9]+)/0 ([0-9]+/[0-9]+)/0 ([0-9]+/[0-9]+)/0#\1 \2
\3#" "Data2.obj" > noNormals.obj
osgviewer -O noRotation  noNormals.obj
Laurens.


On Wed, Jan 15, 2020 at 12:24 PM 'Tom Pollok' via OpenSceneGraph Users <
osg-us...@googlegroups.com> wrote:

> Hello Robert,
>
> 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.
> 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?
>
> For loading, im using only:
>
> osgDB::Options* opt = new 
> osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr 
> node = osgDB::readNodeFile(pathToObjFile, opt);
>
>
> Best,
> Tom
>
>
> Am Dienstag, 14. Januar 2020 17:25:27 UTC+1 schrieb Robert Osfield:
>>
>> On Tue, 14 Jan 2020 at 15:26, 'Tom Pollok' via OpenSceneGraph Users <
>> osg-...@googlegroups.com> wrote:
>>
>>> Thank you for the workaround.
>>>
>>> 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.
>>> So that means that openscenegraph now will be able to display the
>>> textured mesh, even if the normals are missing, right?
>>>
>>
>> Yes, that's correct, you'll get a textured mesh with no normals assigned.
>>
>> Robert.
>>
>>
> --
> You received this message because you are subscribed to the Google Groups
> "OpenSceneGraph Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to osg-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/osg-users/b55a82c5-4801-49da-b1c4-149d868bd6fa%40googlegroups.com
> 
> .
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-15 Thread 'Tom Pollok' via OpenSceneGraph Users
Hello Robert,

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.
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?

For loading, im using only:

osgDB::Options* opt = new 
osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr node 
= osgDB::readNodeFile(pathToObjFile, opt);


Best,
Tom


Am Dienstag, 14. Januar 2020 17:25:27 UTC+1 schrieb Robert Osfield:
>
> On Tue, 14 Jan 2020 at 15:26, 'Tom Pollok' via OpenSceneGraph Users <
> osg-...@googlegroups.com > wrote:
>
>> Thank you for the workaround.
>>
>> 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.
>> So that means that openscenegraph now will be able to display the 
>> textured mesh, even if the normals are missing, right?
>>
>
> Yes, that's correct, you'll get a textured mesh with no normals assigned.
>
> Robert.
>  
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/b55a82c5-4801-49da-b1c4-149d868bd6fa%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread Robert Osfield
On Tue, 14 Jan 2020 at 15:26, 'Tom Pollok' via OpenSceneGraph Users <
osg-us...@googlegroups.com> wrote:

> Thank you for the workaround.
>
> 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.
> So that means that openscenegraph now will be able to display the textured
> mesh, even if the normals are missing, right?
>

Yes, that's correct, you'll get a textured mesh with no normals assigned.

Robert.

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/CAFN7Y%2BU_VueNJeHtW%3DtfpWf5i-mC8JQDyTrjf8F5VZwE06MyHw%40mail.gmail.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread 'Tom Pollok' via OpenSceneGraph Users
Thank you for the workaround.

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.
So that means that openscenegraph now will be able to display the textured 
mesh, even if the normals are missing, right?

Am Dienstag, 14. Januar 2020 16:01:11 UTC+1 schrieb Robert Osfield:
>
> I have checked in a workaround for the invalid indices to the 3.6 branch 
> and master:
>
> 
> https://github.com/openscenegraph/OpenSceneGraph/commit/2b9c501e18b6eded7375c0e272aff401ad9793a2
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/562cb694-52e1-4e80-b64b-909a2e716e79%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread Robert Osfield
I have checked in a workaround for the invalid indices to the 3.6 branch 
and master:


https://github.com/openscenegraph/OpenSceneGraph/commit/2b9c501e18b6eded7375c0e272aff401ad9793a2

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/6c36648e-c762-4b26-b743-3e127eb061c8%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread 'Tom Pollok' via OpenSceneGraph Users


Am Dienstag, 14. Januar 2020 15:23:15 UTC+1 schrieb Robert Osfield:
>
>
> On Tuesday, 14 January 2020 13:54:37 UTC, Tom Pollok wrote:
>>
>> I used OpenMVS to create it:
>>
>> https://github.com/cdcseacave/openMVS
>>
>
> The model isn't a valid .obj file, I am not familiar with OpenMVS and as I 
> have my own open source projects to manage I'll leave it to others to fix 
> OpenMVS.  I would suggest having a look at the .obj export yourself or 
> creating an Issue for it, but a quick look at the github page makes me 
> wonder if the Issue tracker is being largely ignored or misused at there 
> are 95 items in there.
>
 

>  
>
>> I can also view the model using MeshLab or other tools.
>>
>
> These other tools must have added a catch for this type of invalid model.
>  
>
>>
>> Is it possible to fix the invalid references in openscenegraph?
>>
>
> I am currently modifying the OSG's obj loader to catch the invalid data as 
> crashing is as much as a bug as the dodgy data.  I expect to get a fix 
> checked in this afternoon so it'll be part of the OSG-3.6 branch and the up 
> coming 3.6.5 release.
>

> Robert.
>  
>

Thank you Robert for your help and thank you for all your efforts for 
openscenegraph!
Best, Tom.

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/8db7521b-2941-4624-9c75-b71e20ca1453%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread Robert Osfield

On Tuesday, 14 January 2020 13:54:37 UTC, Tom Pollok wrote:
>
> I used OpenMVS to create it:
>
> https://github.com/cdcseacave/openMVS
>

The model isn't a valid .obj file, I am not familiar with OpenMVS and as I 
have my own open source projects to manage I'll leave it to others to fix 
OpenMVS.  I would suggest having a look at the .obj export yourself or 
creating an Issue for it, but a quick look at the github page makes me 
wonder if the Issue tracker is being largely ignored or misused at there 
are 95 items in there.
 

> I can also view the model using MeshLab or other tools.
>

These other tools must have added a catch for this type of invalid model.
 

>
> Is it possible to fix the invalid references in openscenegraph?
>

I am currently modifying the OSG's obj loader to catch the invalid data as 
crashing is as much as a bug as the dodgy data.  I expect to get a fix 
checked in this afternoon so it'll be part of the OSG-3.6 branch and the up 
coming 3.6.5 release.

Robert.
 

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/add84e69-8221-4df2-82a0-fe8c1e174d6b%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread 'Tom Pollok' via OpenSceneGraph Users
Hello Laurens,

thank you for your investigation!

Best,
Tom

Am Dienstag, 14. Januar 2020 14:10:27 UTC+1 schrieb L. Voerman:
>
> repost in google group; It seems like my reply to the mailing list does 
> not show up in google groups.
>
> Hi Tom,
> I think your obj file is invalid, as the faces all reference normal "0" 
> and 
> 1> no normals are provided
> 2> normal indices start at 1 (according to wikipedia 
> )
>
> if I reduce your obj file to just the first face (removing material and 
> all but vertex/texcoord 0-1-2) ( attached )
> I get the same crash with
> osgconv DataFace1.obj
> removing the /0 (normal ref) three times fixes the problem - same works 
> for the large file (with textures working)
> Laurens.
>
> On Monday, January 13, 2020 at 12:12:48 PM UTC+1, Tom Pollok wrote:
>>
>> I added a zip file with the mesh. It happens when loading that obj file.
>>
>> https://owncloud.iosb.fraunhofer.de/owncloud/s/dc8dkbXrQz3gTuh
>>
>> Pw: osg
>>
>> I have to check for the stack trace again.
>>
>> osgDB::Options* opt = new 
>> osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr 
>> node = osgDB::readNodeFile(pathToObjFile, opt);
>>
>> Im using two windows machines with intel processors (64bit). 
>> OSG was built by ourselves. 
>> One has an integrated intel graphics unit and one with a Nvidia 2080Ti.
>>
>>
>> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>>
>>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:

 When loading a textured mesh from an obj file with mtl + texture file, 
 openscenegraph crashes.

 I use openscenegraph 3.4.1. Does anybody know if that issue has been 
 fixed in newer versions?

>>>
>>> I don;t recall reports of crashes associated with .obj.
>>>
>>> Could you provide a link to the model that is causing the problem?
>>>
>>> Could you provide a stack trace?
>>>
>>> What platform are you working on?  Did you build the OSG yourself?  
>>>
>>> What hardware are you working on?
>>>
>>> Cheers,
>>> Robert,
>>>
>>
>>
>> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>>
>>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:

 When loading a textured mesh from an obj file with mtl + texture file, 
 openscenegraph crashes.

 I use openscenegraph 3.4.1. Does anybody know if that issue has been 
 fixed in newer versions?

>>>
>>> I don;t recall reports of crashes associated with .obj.
>>>
>>> Could you provide a link to the model that is causing the problem?
>>>
>>> Could you provide a stack trace?
>>>
>>> What platform are you working on?  Did you build the OSG yourself?  
>>>
>>> What hardware are you working on?
>>>
>>> Cheers,
>>> Robert,
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/35f1fdb6-f7a2-410b-afbf-b2911388438f%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread 'Tom Pollok' via OpenSceneGraph Users
I used OpenMVS to create it:

https://github.com/cdcseacave/openMVS

I can also view the model using MeshLab or other tools.

Is it possible to fix the invalid references in openscenegraph?


Am Dienstag, 14. Januar 2020 14:36:29 UTC+1 schrieb Robert Osfield:
>
> I have looked at the model with the 3.6 branch and get the crash and 
> concur with Luarens - the model is broken, it has normal indices assigned 
> to the faces but no normal array.  The crash occurs because the OSG's obj 
> plugin is assuming that if normal indices are provided they are valid 
> normal indices.
>
> Where did this model come from?
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/f766688a-6560-4b0a-82a9-db3d1dbb4fc8%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread Robert Osfield
I have looked at the model with the 3.6 branch and get the crash and concur 
with Luarens - the model is broken, it has normal indices assigned to the 
faces but no normal array.  The crash occurs because the OSG's obj plugin 
is assuming that if normal indices are provided they are valid normal 
indices.

Where did this model come from?

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/3ad360a9-7e3d-462c-9e6b-b21d344ccdb7%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-14 Thread L. Voerman
repost in google group; It seems like my reply to the mailing list does not 
show up in google groups.

Hi Tom,
I think your obj file is invalid, as the faces all reference normal "0" and 
1> no normals are provided
2> normal indices start at 1 (according to wikipedia 
)

if I reduce your obj file to just the first face (removing material and all 
but vertex/texcoord 0-1-2) ( attached )
I get the same crash with
osgconv DataFace1.obj
removing the /0 (normal ref) three times fixes the problem - same works for 
the large file (with textures working)
Laurens.

On Monday, January 13, 2020 at 12:12:48 PM UTC+1, Tom Pollok wrote:
>
> I added a zip file with the mesh. It happens when loading that obj file.
>
> https://owncloud.iosb.fraunhofer.de/owncloud/s/dc8dkbXrQz3gTuh
>
> Pw: osg
>
> I have to check for the stack trace again.
>
> osgDB::Options* opt = new 
> osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr 
> node = osgDB::readNodeFile(pathToObjFile, opt);
>
> Im using two windows machines with intel processors (64bit). 
> OSG was built by ourselves. 
> One has an integrated intel graphics unit and one with a Nvidia 2080Ti.
>
>
> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>
>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:
>>>
>>> When loading a textured mesh from an obj file with mtl + texture file, 
>>> openscenegraph crashes.
>>>
>>> I use openscenegraph 3.4.1. Does anybody know if that issue has been 
>>> fixed in newer versions?
>>>
>>
>> I don;t recall reports of crashes associated with .obj.
>>
>> Could you provide a link to the model that is causing the problem?
>>
>> Could you provide a stack trace?
>>
>> What platform are you working on?  Did you build the OSG yourself?  
>>
>> What hardware are you working on?
>>
>> Cheers,
>> Robert,
>>
>
>
> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>
>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:
>>>
>>> When loading a textured mesh from an obj file with mtl + texture file, 
>>> openscenegraph crashes.
>>>
>>> I use openscenegraph 3.4.1. Does anybody know if that issue has been 
>>> fixed in newer versions?
>>>
>>
>> I don;t recall reports of crashes associated with .obj.
>>
>> Could you provide a link to the model that is causing the problem?
>>
>> Could you provide a stack trace?
>>
>> What platform are you working on?  Did you build the OSG yourself?  
>>
>> What hardware are you working on?
>>
>> Cheers,
>> Robert,
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/3407e52c-e310-4f8a-ac9c-b04b5247789e%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-13 Thread Voerman, L.
Hi Tom,
I think your obj file is invalid, as the faces all reference normal "0" and
1> no normals are provided
2> normal indices start at 1 (according to wikipedia
)

if I reduce your obj file to just the first face (removing material and all
but vertex/texcoord 0-1-2) ( attached )
I get the same crash with
osgconv DataFace1.obj
removing the /0 (normal ref) three times fixes the problem - same works for
the large file (with textures working)
Laurens.

On Mon, Jan 13, 2020 at 3:15 PM 'Tom Pollok' via OpenSceneGraph Users <
osg-us...@googlegroups.com> wrote:

> Hello Robert,
>
> I added a minimal reproducer and a stracktrace (release). Unfortunately i
> only have release builds on this machine, but I could provide debug stack
> trace from another system later...
>
> Best,
> Tom
>
>
>
> Am Montag, 13. Januar 2020 12:12:48 UTC+1 schrieb Tom Pollok:
>>
>> I added a zip file with the mesh. It happens when loading that obj file.
>>
>> https://owncloud.iosb.fraunhofer.de/owncloud/s/dc8dkbXrQz3gTuh
>>
>> Pw: osg
>>
>> I have to check for the stack trace again.
>>
>> osgDB::Options* opt = new 
>> osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr 
>> node = osgDB::readNodeFile(pathToObjFile, opt);
>>
>> Im using two windows machines with intel processors (64bit).
>> OSG was built by ourselves.
>> One has an integrated intel graphics unit and one with a Nvidia 2080Ti.
>>
>>
>> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>>
>>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:

 When loading a textured mesh from an obj file with mtl + texture file,
 openscenegraph crashes.

 I use openscenegraph 3.4.1. Does anybody know if that issue has been
 fixed in newer versions?

>>>
>>> I don;t recall reports of crashes associated with .obj.
>>>
>>> Could you provide a link to the model that is causing the problem?
>>>
>>> Could you provide a stack trace?
>>>
>>> What platform are you working on?  Did you build the OSG yourself?
>>>
>>> What hardware are you working on?
>>>
>>> Cheers,
>>> Robert,
>>>
>>
>>
>> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>>
>>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:

 When loading a textured mesh from an obj file with mtl + texture file,
 openscenegraph crashes.

 I use openscenegraph 3.4.1. Does anybody know if that issue has been
 fixed in newer versions?

>>>
>>> I don;t recall reports of crashes associated with .obj.
>>>
>>> Could you provide a link to the model that is causing the problem?
>>>
>>> Could you provide a stack trace?
>>>
>>> What platform are you working on?  Did you build the OSG yourself?
>>>
>>> What hardware are you working on?
>>>
>>> Cheers,
>>> Robert,
>>>
>> --
> You received this message because you are subscribed to the Google Groups
> "OpenSceneGraph Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to osg-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/osg-users/e8e0c207-93e6-49ff-accc-2f4e7ba1be6e%40googlegroups.com
> 
> .
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>


DataFace1.obj
Description: Binary data
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-13 Thread 'Tom Pollok' via OpenSceneGraph Users
Hello Robert,

I added a minimal reproducer and a stracktrace (release). Unfortunately i 
only have release builds on this machine, but I could provide debug stack 
trace from another system later...

Best,
Tom



Am Montag, 13. Januar 2020 12:12:48 UTC+1 schrieb Tom Pollok:
>
> I added a zip file with the mesh. It happens when loading that obj file.
>
> https://owncloud.iosb.fraunhofer.de/owncloud/s/dc8dkbXrQz3gTuh
>
> Pw: osg
>
> I have to check for the stack trace again.
>
> osgDB::Options* opt = new 
> osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr 
> node = osgDB::readNodeFile(pathToObjFile, opt);
>
> Im using two windows machines with intel processors (64bit). 
> OSG was built by ourselves. 
> One has an integrated intel graphics unit and one with a Nvidia 2080Ti.
>
>
> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>
>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:
>>>
>>> When loading a textured mesh from an obj file with mtl + texture file, 
>>> openscenegraph crashes.
>>>
>>> I use openscenegraph 3.4.1. Does anybody know if that issue has been 
>>> fixed in newer versions?
>>>
>>
>> I don;t recall reports of crashes associated with .obj.
>>
>> Could you provide a link to the model that is causing the problem?
>>
>> Could you provide a stack trace?
>>
>> What platform are you working on?  Did you build the OSG yourself?  
>>
>> What hardware are you working on?
>>
>> Cheers,
>> Robert,
>>
>
>
> Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>>
>> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:
>>>
>>> When loading a textured mesh from an obj file with mtl + texture file, 
>>> openscenegraph crashes.
>>>
>>> I use openscenegraph 3.4.1. Does anybody know if that issue has been 
>>> fixed in newer versions?
>>>
>>
>> I don;t recall reports of crashes associated with .obj.
>>
>> Could you provide a link to the model that is causing the problem?
>>
>> Could you provide a stack trace?
>>
>> What platform are you working on?  Did you build the OSG yourself?  
>>
>> What hardware are you working on?
>>
>> Cheers,
>> Robert,
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/e8e0c207-93e6-49ff-accc-2f4e7ba1be6e%40googlegroups.com.
<>
.  0  Id: 12bc.2d94 Suspend: 1 Teb: 0062`5477d000 Unfrozen
Child-SP  RetAddr   Call Site
0062`545ed090 7ffd`400749f2 MSVCP140D!std::_Debug_message+0x46
0062`545ed0d0 7ffd`40094947 osgdb_objd+0x449f2
0062`545ed110 7ffd`40094c62 osgdb_objd+0x64947
0062`545ed1f0 7ffd`4005e7c4 osgdb_objd+0x64c62
0062`545ed260 7ffd`4005f18a osgdb_objd+0x2e7c4
0062`545edc30 7ffd`4005c0d7 osgdb_objd+0x2f18a
0062`545ee1b0 7ffd`256206a7 osgdb_objd+0x2c0d7
0062`545ee650 7ffd`255f8d44 
osg131_osgDBd!osgDB::PropertyInputIterator::readBool+0x28b751
0062`545ee690 7ffd`255f9bb7 
osg131_osgDBd!osgDB::PropertyInputIterator::readBool+0x263dee
0062`545eeeb0 7ffd`255f206f 
osg131_osgDBd!osgDB::PropertyInputIterator::readBool+0x264c61
0062`545ef0e0 7ffd`2544c39f 
osg131_osgDBd!osgDB::PropertyInputIterator::readBool+0x25d119
0062`545ef180 7ffd`255eb4f0 
osg131_osgDBd!osgDB::PropertyInputIterator::readBool+0xb7449
0062`545ef300 7ff6`5dd52baa 
osg131_osgDBd!osgDB::PropertyInputIterator::readBool+0x25659a
0062`545ef3c0 7ff6`5dd59f4d osgTest!main(int argc = 0n1, char ** argv = 
0x01dc`a7b57b50)+0x36a
0062`545ef710 7ff6`5dd57bbd osgTest!WinMain(struct HINSTANCE__ * 
__formal = 0x7ff6`5dd5, struct HINSTANCE__ * __formal = 
0x`, char * __formal = 0x01dc`a7b45e07 "", int __formal = 
0n10)+0xed [c:\users\qt\work\qt\qtbase\src\winmain\qtmain_win.cpp @ 104]
0062`545ef790 7ff6`5dd57a67 osgTest!invoke_main(void)+0x2d 
[f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl @ 99]
0062`545ef7d0 7ff6`5dd5792e osgTest!__scrt_common_main_seh(void)+0x127 
[f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl @ 253]
0062`545ef830 7ff6`5dd57bd9 osgTest!__scrt_common_main(void)+0xe 
[f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl @ 296]
0062`545ef860 7ffd`53598364 osgTest!WinMainCRTStartup(void)+0x9 
[f:\dd\vctools\crt\vcstartup\src\startup\exe_winmain.cpp @ 17]
0062`545ef890 7ffd`53977091 KERNEL32!BaseThreadInitThunk+0x14
0062`545ef8c0 ` ntdll!RtlUserThreadStart+0x21

   1  Id: 12bc.2a88 Suspend: 1 Teb: 0062`5477f000 Unfrozen
Child-SP  RetAddr   Call Site
0062`548ff5c8 7ffd`5394354e ntdll!ZwWaitForWorkViaWorkerFactory+0x14
0062`548ff5d0 7ffd`53598364 ntdll!RtlReleaseSRWLockExclusive+0x1ade
0062`548ff9d0 7ff

Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-13 Thread 'Tom Pollok' via OpenSceneGraph Users
I added a zip file with the mesh. It happens when loading that obj file.

https://owncloud.iosb.fraunhofer.de/owncloud/s/dc8dkbXrQz3gTuh

Pw: osg

I have to check for the stack trace again.

osgDB::Options* opt = new 
osgDB::Options;opt->setOptionString("noRotation");osg::ref_ptr node 
= osgDB::readNodeFile(pathToObjFile, opt);

Im using two windows machines with intel processors (64bit). 
OSG was built by ourselves. 
One has an integrated intel graphics unit and one with a Nvidia 2080Ti.


Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>
> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:
>>
>> When loading a textured mesh from an obj file with mtl + texture file, 
>> openscenegraph crashes.
>>
>> I use openscenegraph 3.4.1. Does anybody know if that issue has been 
>> fixed in newer versions?
>>
>
> I don;t recall reports of crashes associated with .obj.
>
> Could you provide a link to the model that is causing the problem?
>
> Could you provide a stack trace?
>
> What platform are you working on?  Did you build the OSG yourself?  
>
> What hardware are you working on?
>
> Cheers,
> Robert,
>


Am Freitag, 10. Januar 2020 19:45:26 UTC+1 schrieb Robert Osfield:
>
> On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:
>>
>> When loading a textured mesh from an obj file with mtl + texture file, 
>> openscenegraph crashes.
>>
>> I use openscenegraph 3.4.1. Does anybody know if that issue has been 
>> fixed in newer versions?
>>
>
> I don;t recall reports of crashes associated with .obj.
>
> Could you provide a link to the model that is causing the problem?
>
> Could you provide a stack trace?
>
> What platform are you working on?  Did you build the OSG yourself?  
>
> What hardware are you working on?
>
> Cheers,
> Robert,
>

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/4464ef67-e303-45cf-adce-c68472d0d558%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-10 Thread Robert Osfield
On Friday, 10 January 2020 18:01:57 UTC, Tom Pollok wrote:
>
> When loading a textured mesh from an obj file with mtl + texture file, 
> openscenegraph crashes.
>
> I use openscenegraph 3.4.1. Does anybody know if that issue has been fixed 
> in newer versions?
>

I don;t recall reports of crashes associated with .obj.

Could you provide a link to the model that is causing the problem?

Could you provide a stack trace?

What platform are you working on?  Did you build the OSG yourself?  

What hardware are you working on?

Cheers,
Robert,

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/3cd85069-be12-48b7-96d6-679348a35f50%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Loading textured meshes (obj+mtl) leads to crash in osg 3.4.1

2020-01-10 Thread 'Tom Pollok' via OpenSceneGraph Users
When loading a textured mesh from an obj file with mtl + texture file, 
openscenegraph crashes.

I use openscenegraph 3.4.1. Does anybody know if that issue has been fixed 
in newer versions?

-- 
You received this message because you are subscribed to the Google Groups 
"OpenSceneGraph Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osg-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osg-users/a6713d30-91b6-49b3-a240-d98f87781461%40googlegroups.com.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org