Re: [osg-users] osg_NormalMatrix calculated incorrectly

2012-04-19 Thread Paul Martz
I just confirmed that this is fixed by David's submission in r13067. -Paul On 4/12/2012 10:22 PM, Roland Hill wrote: Hi, I believe osg_NormalMatrix may be being calculated incorrectly in the trunk version of OSG. At present, it is calculated as the inverse 3x3 of the modelview matrix,

Re: [osg-users] osg_NormalMatrix calculated incorrectly

2012-04-15 Thread Paul Martz
The weekend has been a total loss work-wise, so I didn't get too far with this, sorry. But I did back-date trunk to r13018, which was the last time oversimple3.cpp was modified, and the lines of code in your proposed change haven't been modified since then either. The example ran and lit

Re: [osg-users] osg_NormalMatrix calculated incorrectly

2012-04-15 Thread Roland Hill
Hi Paul, Thanks for looking into this. At least I know that it can be replicated outside my environment! Cheers, Roland -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=47064#47064 ___ osg-users

Re: [osg-users] osg_NormalMatrix calculated incorrectly

2012-04-15 Thread Paul Martz
Hi Roland -- I dug in quite a bit further this evening and have narrowed down the issue only a little. The issue seems to be related to r13050, r13059, and the latest r13060, so I've copied their authors on this post to solicit their feedback on this thread and help track down what the root

Re: [osg-users] osg_NormalMatrix calculated incorrectly

2012-04-15 Thread Roland Hill
Hi Paul, Just a bit more information from me. I'm using Ubuntu 11.04 64 bit on two machines (1 Nividia 1 ATI). I also compiled for Win64 and got the same result. I'm building OSG for GL2 - the only deviation from a 'standard' build is that I disable Display Lists on both machines otherwise

Re: [osg-users] osg_NormalMatrix calculated incorrectly

2012-04-13 Thread Paul Martz
Something odd is going on here, as this works correctly in 3.0.1. I don't have time to dig in to the math right now; maybe over the weekend... -Paul On 4/12/2012 10:22 PM, Roland Hill wrote: Hi, I believe osg_NormalMatrix may be being calculated incorrectly in the trunk version of OSG.

[osg-users] osg_NormalMatrix calculated incorrectly

2012-04-12 Thread Roland Hill
Hi, I believe osg_NormalMatrix may be being calculated incorrectly in the trunk version of OSG. At present, it is calculated as the inverse 3x3 of the modelview matrix, but should be the transpose inverse. The patch below appears to correct this. To test, try running osgsimplegl3 cow.osg. You