<div dir="ltr"><div>Hi David,</div><div><br></div><div>to set up a Quat with your hpr you can do something like this:</div><div>osg::Quat q;</div><div>q.makeRotate(h,osg::Vec3(0,0,1),p,osg::Vec3(1,0,0),r,osg::Vec3(0,1,0));</div><div><br></div><div>of course you can tune the order</div><div><br></div><div>Cheers,</div><div>Nick<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, May 2, 2019 at 11:02 PM David Bobavid <<a href="mailto:david.bobavid@gmail.com">david.bobavid@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Eran,<br>
<br>
Ok, thanks! I'll look into that.<br>
<br>
Last question (I think) for now... I'm trying to set my cow's orientation. From what you have suggested previously, would I add another MatrixTransform node with the rotations set into it? <br>
<br>
Or should I add a PositionAttitudeTransform instead? If so, are there some helper classes that I can use that will create the Quat properly based on my heading, pitch and roll? I've been looking through the headers and cannot seem to find something that will help.<br>
<br>
Thank you again!<br>
<br>
Cheers,<br>
David<br>
<br>
------------------<br>
Read this topic online here:<br>
<a href="http://forum.openscenegraph.org/viewtopic.php?p=75944#75944" rel="noreferrer" target="_blank">http://forum.openscenegraph.org/viewtopic.php?p=75944#75944</a><br>
<br>
<br>
<br>
<br>
<br>
_______________________________________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org" target="_blank">osg-users@lists.openscenegraph.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org</a><br>
</blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="gmail_signature">trajce nikolov nick<br></div>