106
94
<div class="title">Frame Class Reference</div> </div>
107
95
</div><!--header-->
108
96
<div class="contents">
109
<!-- doxytag: class="qglviewer::Frame" -->
110
98
<p>The Frame class represents a coordinate system, defined by a position and an orientation.
111
99
<a href="classqglviewer_1_1Frame.html#details">More...</a></p>
113
101
<p><a href="classqglviewer_1_1Frame-members.html">List of all members.</a></p>
114
102
<table class="memberdecls">
115
<tr><td colspan="2"><h2><a name="signals"></a>
103
<tr class="heading"><td colspan="2"><h2><a name="signals"></a>
116
104
Signals</h2></td></tr>
117
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a> ()</td></tr>
118
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab55c2a4f1732b90057fae4b6037399de">interpolated</a> ()</td></tr>
119
<tr><td colspan="2"><h2><a name="pub-methods"></a>
105
<tr class="memitem:ab6722375e68e03d151762ebfc83c5459"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a> ()</td></tr>
106
<tr class="memitem:ab55c2a4f1732b90057fae4b6037399de"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab55c2a4f1732b90057fae4b6037399de">interpolated</a> ()</td></tr>
107
</table><table class="memberdecls">
108
<tr class="heading"><td colspan="2"><h2><a name="pub-methods"></a>
120
109
Public Member Functions</h2></td></tr>
121
<tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a> ()</td></tr>
122
<tr><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ae0c994a30d9a018000fe8ad66ff0a86d">~Frame</a> ()</td></tr>
123
<tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7864fb955cec11fe78c3b2bb81230516">Frame</a> (const Frame &frame)</td></tr>
124
<tr><td class="memItemLeft" align="right" valign="top">Frame & </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aeb0f5ceffbb62f990b89b200d6ce728c">operator=</a> (const Frame &frame)</td></tr>
125
<tr><td colspan="2"><h2><a name="member-group"></a>
110
<tr class="memitem:ab71e6ee46f0c2593266f9a62d9c5e029"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a> ()</td></tr>
111
<tr class="memitem:ae0c994a30d9a018000fe8ad66ff0a86d"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ae0c994a30d9a018000fe8ad66ff0a86d">~Frame</a> ()</td></tr>
112
<tr class="memitem:a7864fb955cec11fe78c3b2bb81230516"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7864fb955cec11fe78c3b2bb81230516">Frame</a> (const Frame &frame)</td></tr>
113
<tr class="memitem:aeb0f5ceffbb62f990b89b200d6ce728c"><td class="memItemLeft" align="right" valign="top">Frame & </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aeb0f5ceffbb62f990b89b200d6ce728c">operator=</a> (const Frame &frame)</td></tr>
114
</table><table class="memberdecls">
115
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
126
116
World coordinates position and orientation</h2></td></tr>
127
<tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a2f649a1218291aa3776ce08d0a2879b1">Frame</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>, const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
128
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a24f5da9b3f4bf4e71dfad7a74a932e52">setPosition</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>)</td></tr>
129
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aff7308b903966afc6c87b5cd766a9083">setPosition</a> (float x, float y, float z)</td></tr>
130
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5081403cb47f1324edae5278d5438a38">setPositionWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>)</td></tr>
131
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a6733704520780505759efdef38a68b8b">setOrientation</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
132
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ae3ac2bf6dcfe21252d40325789503ce6">setOrientation</a> (double q0, double q1, double q2, double q3)</td></tr>
133
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a8b69106a268d78daf27d32854d455da4">setOrientationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
134
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a47912d16be51eb85d68d3dcb4a4fb087">setPositionAndOrientation</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>, const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
135
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a8501c5582c1aa2a82a929ce36439ab3a">setPositionAndOrientationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>, <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
136
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a> () const </td></tr>
137
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a> () const </td></tr>
138
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab3ca600424074ccaf5ee078c8d3149c3">getPosition</a> (float &x, float &y, float &z) const </td></tr>
139
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac47c3b7fd6023734ba40249bea1fd253">getOrientation</a> (double &q0, double &q1, double &q2, double &q3) const </td></tr>
140
<tr><td colspan="2"><h2><a name="member-group"></a>
117
<tr class="memitem:a2f649a1218291aa3776ce08d0a2879b1"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a2f649a1218291aa3776ce08d0a2879b1">Frame</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>, const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
118
<tr class="memitem:a24f5da9b3f4bf4e71dfad7a74a932e52"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a24f5da9b3f4bf4e71dfad7a74a932e52">setPosition</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>)</td></tr>
119
<tr class="memitem:aff7308b903966afc6c87b5cd766a9083"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aff7308b903966afc6c87b5cd766a9083">setPosition</a> (float x, float y, float z)</td></tr>
120
<tr class="memitem:a5081403cb47f1324edae5278d5438a38"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5081403cb47f1324edae5278d5438a38">setPositionWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>)</td></tr>
121
<tr class="memitem:a6733704520780505759efdef38a68b8b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a6733704520780505759efdef38a68b8b">setOrientation</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
122
<tr class="memitem:ae3ac2bf6dcfe21252d40325789503ce6"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ae3ac2bf6dcfe21252d40325789503ce6">setOrientation</a> (double q0, double q1, double q2, double q3)</td></tr>
123
<tr class="memitem:a8b69106a268d78daf27d32854d455da4"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a8b69106a268d78daf27d32854d455da4">setOrientationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
124
<tr class="memitem:a47912d16be51eb85d68d3dcb4a4fb087"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a47912d16be51eb85d68d3dcb4a4fb087">setPositionAndOrientation</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>, const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
125
<tr class="memitem:a8501c5582c1aa2a82a929ce36439ab3a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a8501c5582c1aa2a82a929ce36439ab3a">setPositionAndOrientationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a>, <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a>)</td></tr>
126
<tr class="memitem:abc38a05a597e07c9ff525122682adc50"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position</a> () const </td></tr>
127
<tr class="memitem:a691af39b54669fad8b4e73599de22094"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation</a> () const </td></tr>
128
<tr class="memitem:ab3ca600424074ccaf5ee078c8d3149c3"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab3ca600424074ccaf5ee078c8d3149c3">getPosition</a> (float &x, float &y, float &z) const </td></tr>
129
<tr class="memitem:ac47c3b7fd6023734ba40249bea1fd253"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac47c3b7fd6023734ba40249bea1fd253">getOrientation</a> (double &q0, double &q1, double &q2, double &q3) const </td></tr>
130
</table><table class="memberdecls">
131
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
141
132
Local translation and rotation w/r reference Frame</h2></td></tr>
142
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ae5495cd791858225ba7c85ce39329704">setTranslation</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>)</td></tr>
143
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aeafb612e3ad0d6a81de91884eb4bdef1">setTranslation</a> (float x, float y, float z)</td></tr>
144
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7f3395d24d164a7af9a8b99e4e6bafc0">setTranslationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>)</td></tr>
145
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a857aacdb88a574ec4a363335f6152a1e">setRotation</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
146
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a26c462ecae655fa82c4d2efa42f9cd2e">setRotation</a> (double q0, double q1, double q2, double q3)</td></tr>
147
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a9d4ab1388820d002d44304c5463fbfbd">setRotationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
148
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a0fbfd129a52b36b6753cc1589ff87a48">setTranslationAndRotation</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>, const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
149
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a3a08480e8de4a36536ff95e0f05303db">setTranslationAndRotationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>, <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
150
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a> () const </td></tr>
151
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a> () const </td></tr>
152
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a39804059e5c4e694a6cb13b71347da97">getTranslation</a> (float &x, float &y, float &z) const </td></tr>
153
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a475a20f772ff87508b673a586fc50bbb">getRotation</a> (double &q0, double &q1, double &q2, double &q3) const </td></tr>
154
<tr><td colspan="2"><h2><a name="member-group"></a>
133
<tr class="memitem:ae5495cd791858225ba7c85ce39329704"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ae5495cd791858225ba7c85ce39329704">setTranslation</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>)</td></tr>
134
<tr class="memitem:aeafb612e3ad0d6a81de91884eb4bdef1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aeafb612e3ad0d6a81de91884eb4bdef1">setTranslation</a> (float x, float y, float z)</td></tr>
135
<tr class="memitem:a7f3395d24d164a7af9a8b99e4e6bafc0"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7f3395d24d164a7af9a8b99e4e6bafc0">setTranslationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>)</td></tr>
136
<tr class="memitem:a857aacdb88a574ec4a363335f6152a1e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a857aacdb88a574ec4a363335f6152a1e">setRotation</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
137
<tr class="memitem:a26c462ecae655fa82c4d2efa42f9cd2e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a26c462ecae655fa82c4d2efa42f9cd2e">setRotation</a> (double q0, double q1, double q2, double q3)</td></tr>
138
<tr class="memitem:a9d4ab1388820d002d44304c5463fbfbd"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a9d4ab1388820d002d44304c5463fbfbd">setRotationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
139
<tr class="memitem:a0fbfd129a52b36b6753cc1589ff87a48"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a0fbfd129a52b36b6753cc1589ff87a48">setTranslationAndRotation</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>, const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
140
<tr class="memitem:a3a08480e8de4a36536ff95e0f05303db"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a3a08480e8de4a36536ff95e0f05303db">setTranslationAndRotationWithConstraint</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &<a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a>, <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>)</td></tr>
141
<tr class="memitem:a388a5f38140104323aa51fc207fde642"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation</a> () const </td></tr>
142
<tr class="memitem:a19ee9243c60f412dfc4eac3dcf45a5a1"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a> () const </td></tr>
143
<tr class="memitem:a39804059e5c4e694a6cb13b71347da97"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a39804059e5c4e694a6cb13b71347da97">getTranslation</a> (float &x, float &y, float &z) const </td></tr>
144
<tr class="memitem:a475a20f772ff87508b673a586fc50bbb"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a475a20f772ff87508b673a586fc50bbb">getRotation</a> (double &q0, double &q1, double &q2, double &q3) const </td></tr>
145
</table><table class="memberdecls">
146
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
155
147
Frame hierarchy</h2></td></tr>
156
<tr><td class="memItemLeft" align="right" valign="top">const Frame * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame</a> () const </td></tr>
157
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#abca9e0c2e40957fffeee4a52139facd8">setReferenceFrame</a> (const Frame *const refFrame)</td></tr>
158
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aa4891a91c825effc65b73f1329ae49c7">settingAsReferenceFrameWillCreateALoop</a> (const Frame *const frame)</td></tr>
159
<tr><td colspan="2"><h2><a name="member-group"></a>
148
<tr class="memitem:a9794b079db5f492e8804631d3d23baec"><td class="memItemLeft" align="right" valign="top">const Frame * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame</a> () const </td></tr>
149
<tr class="memitem:abca9e0c2e40957fffeee4a52139facd8"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#abca9e0c2e40957fffeee4a52139facd8">setReferenceFrame</a> (const Frame *const refFrame)</td></tr>
150
<tr class="memitem:aa4891a91c825effc65b73f1329ae49c7"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aa4891a91c825effc65b73f1329ae49c7">settingAsReferenceFrameWillCreateALoop</a> (const Frame *const frame)</td></tr>
151
</table><table class="memberdecls">
152
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
160
153
Frame modification</h2></td></tr>
161
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4cb0cf5ff79e1acf0755befdaceb6f4a">translate</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &t)</td></tr>
162
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac774331eeae8d29acc94f5653b2f2c3b">translate</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &t)</td></tr>
163
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a9081ed23141a5980f028b21d58fa3290">translate</a> (float x, float y, float z)</td></tr>
164
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a2ae644799a164d7519769ba393565c5d">translate</a> (float &x, float &y, float &z)</td></tr>
165
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a38dffd6ee0ad7e395b49082b2b94de33">rotate</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &q)</td></tr>
166
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac754417fa609300f980fcba5405c9989">rotate</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &q)</td></tr>
167
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7fe03bbf807b109c1edb849193d03aa8">rotate</a> (double q0, double q1, double q2, double q3)</td></tr>
168
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab15e32161293dce94ae3df3bc3a7b0ad">rotate</a> (double &q0, double &q1, double &q2, double &q3)</td></tr>
169
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a85f48572c1298bc3192f111e8b587bca">rotateAroundPoint</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>, const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &point)</td></tr>
170
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5f87bae05096c99fb3b30cf5bb52c891">rotateAroundPoint</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>, const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &point)</td></tr>
171
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a352fc1d1f806653677eabcdb8a5eb898">alignWithFrame</a> (const Frame *const frame, bool move=false, float threshold=0.85f)</td></tr>
172
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#af97ae9e790033879dfcb9837a7312255">projectOnLine</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &origin, const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &direction)</td></tr>
173
<tr><td colspan="2"><h2><a name="member-group"></a>
154
<tr class="memitem:a4cb0cf5ff79e1acf0755befdaceb6f4a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4cb0cf5ff79e1acf0755befdaceb6f4a">translate</a> (<a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &t)</td></tr>
155
<tr class="memitem:ac774331eeae8d29acc94f5653b2f2c3b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac774331eeae8d29acc94f5653b2f2c3b">translate</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &t)</td></tr>
156
<tr class="memitem:a9081ed23141a5980f028b21d58fa3290"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a9081ed23141a5980f028b21d58fa3290">translate</a> (float x, float y, float z)</td></tr>
157
<tr class="memitem:a2ae644799a164d7519769ba393565c5d"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a2ae644799a164d7519769ba393565c5d">translate</a> (float &x, float &y, float &z)</td></tr>
158
<tr class="memitem:a38dffd6ee0ad7e395b49082b2b94de33"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a38dffd6ee0ad7e395b49082b2b94de33">rotate</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &q)</td></tr>
159
<tr class="memitem:ac754417fa609300f980fcba5405c9989"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac754417fa609300f980fcba5405c9989">rotate</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &q)</td></tr>
160
<tr class="memitem:a7fe03bbf807b109c1edb849193d03aa8"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7fe03bbf807b109c1edb849193d03aa8">rotate</a> (double q0, double q1, double q2, double q3)</td></tr>
161
<tr class="memitem:ab15e32161293dce94ae3df3bc3a7b0ad"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ab15e32161293dce94ae3df3bc3a7b0ad">rotate</a> (double &q0, double &q1, double &q2, double &q3)</td></tr>
162
<tr class="memitem:a85f48572c1298bc3192f111e8b587bca"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a85f48572c1298bc3192f111e8b587bca">rotateAroundPoint</a> (<a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>, const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &point)</td></tr>
163
<tr class="memitem:a5f87bae05096c99fb3b30cf5bb52c891"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5f87bae05096c99fb3b30cf5bb52c891">rotateAroundPoint</a> (const <a class="el" href="classqglviewer_1_1Quaternion.html">Quaternion</a> &<a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation</a>, const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &point)</td></tr>
164
<tr class="memitem:a352fc1d1f806653677eabcdb8a5eb898"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a352fc1d1f806653677eabcdb8a5eb898">alignWithFrame</a> (const Frame *const frame, bool move=false, float threshold=0.85f)</td></tr>
165
<tr class="memitem:af97ae9e790033879dfcb9837a7312255"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#af97ae9e790033879dfcb9837a7312255">projectOnLine</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &origin, const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &direction)</td></tr>
166
</table><table class="memberdecls">
167
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
174
168
Coordinate system transformation of 3D coordinates</h2></td></tr>
175
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac706b338b08d9d7b511fd84d0b6ecf96">coordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
176
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5bcb22a3f2e11e42e7469602b75b3c1e">inverseCoordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
177
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a2b113688a0cab6c439dfbf598fd45e70">localCoordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
178
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4e6ac1c504a2f70fdbc0e7383c1aa7c7">localInverseCoordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
179
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a8c3c1e66b248a0f29e304e6c786b9391">coordinatesOfIn</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const in) const </td></tr>
180
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aadad46a46365f6977e4aac6dc18318ce">coordinatesOfFrom</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const from) const </td></tr>
181
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a3718dc9cc825c674c8da3576b1448764">getCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
182
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aede4243bfe48e6d870a2417bbfc711a8">getInverseCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
183
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#abe456b2ee906b9def0d2ec0c949a9497">getLocalCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
184
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#adbd3252d2089f077e23e78345b3723c2">getLocalInverseCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
185
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#af2748e8dd6a4edad38d195132a8c8b30">getCoordinatesOfIn</a> (const float src[3], float res[3], const Frame *const in) const </td></tr>
186
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a36a2d7b27ab27bcff37ab9cbfab20a17">getCoordinatesOfFrom</a> (const float src[3], float res[3], const Frame *const from) const </td></tr>
187
<tr><td colspan="2"><h2><a name="member-group"></a>
169
<tr class="memitem:ac706b338b08d9d7b511fd84d0b6ecf96"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac706b338b08d9d7b511fd84d0b6ecf96">coordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
170
<tr class="memitem:a5bcb22a3f2e11e42e7469602b75b3c1e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5bcb22a3f2e11e42e7469602b75b3c1e">inverseCoordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
171
<tr class="memitem:a2b113688a0cab6c439dfbf598fd45e70"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a2b113688a0cab6c439dfbf598fd45e70">localCoordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
172
<tr class="memitem:a4e6ac1c504a2f70fdbc0e7383c1aa7c7"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4e6ac1c504a2f70fdbc0e7383c1aa7c7">localInverseCoordinatesOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
173
<tr class="memitem:a8c3c1e66b248a0f29e304e6c786b9391"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a8c3c1e66b248a0f29e304e6c786b9391">coordinatesOfIn</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const in) const </td></tr>
174
<tr class="memitem:aadad46a46365f6977e4aac6dc18318ce"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aadad46a46365f6977e4aac6dc18318ce">coordinatesOfFrom</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const from) const </td></tr>
175
<tr class="memitem:a3718dc9cc825c674c8da3576b1448764"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a3718dc9cc825c674c8da3576b1448764">getCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
176
<tr class="memitem:aede4243bfe48e6d870a2417bbfc711a8"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aede4243bfe48e6d870a2417bbfc711a8">getInverseCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
177
<tr class="memitem:abe456b2ee906b9def0d2ec0c949a9497"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#abe456b2ee906b9def0d2ec0c949a9497">getLocalCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
178
<tr class="memitem:adbd3252d2089f077e23e78345b3723c2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#adbd3252d2089f077e23e78345b3723c2">getLocalInverseCoordinatesOf</a> (const float src[3], float res[3]) const </td></tr>
179
<tr class="memitem:af2748e8dd6a4edad38d195132a8c8b30"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#af2748e8dd6a4edad38d195132a8c8b30">getCoordinatesOfIn</a> (const float src[3], float res[3], const Frame *const in) const </td></tr>
180
<tr class="memitem:a36a2d7b27ab27bcff37ab9cbfab20a17"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a36a2d7b27ab27bcff37ab9cbfab20a17">getCoordinatesOfFrom</a> (const float src[3], float res[3], const Frame *const from) const </td></tr>
181
</table><table class="memberdecls">
182
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
188
183
Coordinate system transformation of vectors</h2></td></tr>
189
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a05a3e18419f02427366a95b1e299f12e">transformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
190
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aba2c6c46c1825a81f09d22322b03d9b5">inverseTransformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
191
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a37239448835f46771b9598a31b964cf2">localTransformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
192
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ad36cf320ff7cf6c8f9a2ac527c924f9e">localInverseTransformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
193
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a01636f93c09d6fd9fca90cb671afdda0">transformOfIn</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const in) const </td></tr>
194
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a3416ca5a53c1f2d932fca1906ec1c6c7">transformOfFrom</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const from) const </td></tr>
195
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aac70b883f8e3635d88356cb08b1abae3">getTransformOf</a> (const float src[3], float res[3]) const </td></tr>
196
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a6a2eb1467ca31f7db460a2d6b7166a07">getInverseTransformOf</a> (const float src[3], float res[3]) const </td></tr>
197
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a6e4aeb1d5aafee31442cc3c82a6ee215">getLocalTransformOf</a> (const float src[3], float res[3]) const </td></tr>
198
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a62b201feca5e0ebecc03a71b9566d97c">getLocalInverseTransformOf</a> (const float src[3], float res[3]) const </td></tr>
199
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7d36c3c2d4b004b3e5d296aa58541f9f">getTransformOfIn</a> (const float src[3], float res[3], const Frame *const in) const </td></tr>
200
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4eed4b2770a62e5ebb32d3dcee642c52">getTransformOfFrom</a> (const float src[3], float res[3], const Frame *const from) const </td></tr>
201
<tr><td colspan="2"><h2><a name="member-group"></a>
184
<tr class="memitem:a05a3e18419f02427366a95b1e299f12e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a05a3e18419f02427366a95b1e299f12e">transformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
185
<tr class="memitem:aba2c6c46c1825a81f09d22322b03d9b5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aba2c6c46c1825a81f09d22322b03d9b5">inverseTransformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
186
<tr class="memitem:a37239448835f46771b9598a31b964cf2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a37239448835f46771b9598a31b964cf2">localTransformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
187
<tr class="memitem:ad36cf320ff7cf6c8f9a2ac527c924f9e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ad36cf320ff7cf6c8f9a2ac527c924f9e">localInverseTransformOf</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src) const </td></tr>
188
<tr class="memitem:a01636f93c09d6fd9fca90cb671afdda0"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a01636f93c09d6fd9fca90cb671afdda0">transformOfIn</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const in) const </td></tr>
189
<tr class="memitem:a3416ca5a53c1f2d932fca1906ec1c6c7"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a3416ca5a53c1f2d932fca1906ec1c6c7">transformOfFrom</a> (const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> &src, const Frame *const from) const </td></tr>
190
<tr class="memitem:aac70b883f8e3635d88356cb08b1abae3"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aac70b883f8e3635d88356cb08b1abae3">getTransformOf</a> (const float src[3], float res[3]) const </td></tr>
191
<tr class="memitem:a6a2eb1467ca31f7db460a2d6b7166a07"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a6a2eb1467ca31f7db460a2d6b7166a07">getInverseTransformOf</a> (const float src[3], float res[3]) const </td></tr>
192
<tr class="memitem:a6e4aeb1d5aafee31442cc3c82a6ee215"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a6e4aeb1d5aafee31442cc3c82a6ee215">getLocalTransformOf</a> (const float src[3], float res[3]) const </td></tr>
193
<tr class="memitem:a62b201feca5e0ebecc03a71b9566d97c"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a62b201feca5e0ebecc03a71b9566d97c">getLocalInverseTransformOf</a> (const float src[3], float res[3]) const </td></tr>
194
<tr class="memitem:a7d36c3c2d4b004b3e5d296aa58541f9f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a7d36c3c2d4b004b3e5d296aa58541f9f">getTransformOfIn</a> (const float src[3], float res[3], const Frame *const in) const </td></tr>
195
<tr class="memitem:a4eed4b2770a62e5ebb32d3dcee642c52"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4eed4b2770a62e5ebb32d3dcee642c52">getTransformOfFrom</a> (const float src[3], float res[3], const Frame *const from) const </td></tr>
196
</table><table class="memberdecls">
197
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
202
198
Constraint on the displacement</h2></td></tr>
203
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Constraint.html">Constraint</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a0974dfe336ed84a20adb8c6cdf8dedd9">constraint</a> () const </td></tr>
204
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#adffa44cd173714b29f2441848a39c224">setConstraint</a> (<a class="el" href="classqglviewer_1_1Constraint.html">Constraint</a> *const <a class="el" href="classqglviewer_1_1Frame.html#a0974dfe336ed84a20adb8c6cdf8dedd9">constraint</a>)</td></tr>
205
<tr><td colspan="2"><h2><a name="member-group"></a>
199
<tr class="memitem:a0974dfe336ed84a20adb8c6cdf8dedd9"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classqglviewer_1_1Constraint.html">Constraint</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a0974dfe336ed84a20adb8c6cdf8dedd9">constraint</a> () const </td></tr>
200
<tr class="memitem:adffa44cd173714b29f2441848a39c224"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#adffa44cd173714b29f2441848a39c224">setConstraint</a> (<a class="el" href="classqglviewer_1_1Constraint.html">Constraint</a> *const <a class="el" href="classqglviewer_1_1Frame.html#a0974dfe336ed84a20adb8c6cdf8dedd9">constraint</a>)</td></tr>
201
</table><table class="memberdecls">
202
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
206
203
Associated matrices</h2></td></tr>
207
<tr><td class="memItemLeft" align="right" valign="top">const GLdouble * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aa12123cf45f68b9f7fe0526b70ab0047">matrix</a> () const </td></tr>
208
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4915640a54a6b48a99cbdd0cd42fec48">getMatrix</a> (GLdouble m[4][4]) const </td></tr>
209
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a15f0dc7596dc78437154302466ac3c0a">getMatrix</a> (GLdouble m[16]) const </td></tr>
210
<tr><td class="memItemLeft" align="right" valign="top">const GLdouble * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a39aa0648db05006e2b2f22ac5d971141">worldMatrix</a> () const </td></tr>
211
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a45358fae434b3912ce81577dc7cf4fc9">getWorldMatrix</a> (GLdouble m[4][4]) const </td></tr>
212
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac808850371649942726dd474aba29ead">getWorldMatrix</a> (GLdouble m[16]) const </td></tr>
213
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5408d08ab204157ec29f555b6813f9e4">setFromMatrix</a> (const GLdouble m[4][4])</td></tr>
214
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a0c4d51f142f43235e30198e7b8abc626">setFromMatrix</a> (const GLdouble m[16])</td></tr>
215
<tr><td colspan="2"><h2><a name="member-group"></a>
204
<tr class="memitem:aa12123cf45f68b9f7fe0526b70ab0047"><td class="memItemLeft" align="right" valign="top">const GLdouble * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#aa12123cf45f68b9f7fe0526b70ab0047">matrix</a> () const </td></tr>
205
<tr class="memitem:a4915640a54a6b48a99cbdd0cd42fec48"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4915640a54a6b48a99cbdd0cd42fec48">getMatrix</a> (GLdouble m[4][4]) const </td></tr>
206
<tr class="memitem:a15f0dc7596dc78437154302466ac3c0a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a15f0dc7596dc78437154302466ac3c0a">getMatrix</a> (GLdouble m[16]) const </td></tr>
207
<tr class="memitem:a39aa0648db05006e2b2f22ac5d971141"><td class="memItemLeft" align="right" valign="top">const GLdouble * </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a39aa0648db05006e2b2f22ac5d971141">worldMatrix</a> () const </td></tr>
208
<tr class="memitem:a45358fae434b3912ce81577dc7cf4fc9"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a45358fae434b3912ce81577dc7cf4fc9">getWorldMatrix</a> (GLdouble m[4][4]) const </td></tr>
209
<tr class="memitem:ac808850371649942726dd474aba29ead"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#ac808850371649942726dd474aba29ead">getWorldMatrix</a> (GLdouble m[16]) const </td></tr>
210
<tr class="memitem:a5408d08ab204157ec29f555b6813f9e4"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a5408d08ab204157ec29f555b6813f9e4">setFromMatrix</a> (const GLdouble m[4][4])</td></tr>
211
<tr class="memitem:a0c4d51f142f43235e30198e7b8abc626"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a0c4d51f142f43235e30198e7b8abc626">setFromMatrix</a> (const GLdouble m[16])</td></tr>
212
</table><table class="memberdecls">
213
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
216
214
Inversion of the transformation</h2></td></tr>
217
<tr><td class="memItemLeft" align="right" valign="top">Frame </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4534c3188c217feb8d21465d4cefd4ad">inverse</a> () const </td></tr>
218
<tr><td class="memItemLeft" align="right" valign="top">Frame </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a37d4da8cfd297273e7bb55538debaa3e">worldInverse</a> () const </td></tr>
219
<tr><td colspan="2"><h2><a name="member-group"></a>
215
<tr class="memitem:a4534c3188c217feb8d21465d4cefd4ad"><td class="memItemLeft" align="right" valign="top">Frame </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a4534c3188c217feb8d21465d4cefd4ad">inverse</a> () const </td></tr>
216
<tr class="memitem:a37d4da8cfd297273e7bb55538debaa3e"><td class="memItemLeft" align="right" valign="top">Frame </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a37d4da8cfd297273e7bb55538debaa3e">worldInverse</a> () const </td></tr>
217
</table><table class="memberdecls">
218
<tr class="heading"><td colspan="2"><h2><a name="member-group"></a>
220
219
XML representation</h2></td></tr>
221
<tr><td class="memItemLeft" align="right" valign="top">virtual QDomElement </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a48e0e2dd26cd96418c8b889ceabe80f6">domElement</a> (const QString &name, QDomDocument &document) const </td></tr>
222
<tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#acd13d2ddeca530cb9f26ead47f7d25d3">initFromDOMElement</a> (const QDomElement &element)</td></tr>
220
<tr class="memitem:a48e0e2dd26cd96418c8b889ceabe80f6"><td class="memItemLeft" align="right" valign="top">virtual QDomElement </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#a48e0e2dd26cd96418c8b889ceabe80f6">domElement</a> (const QString &name, QDomDocument &document) const </td></tr>
221
<tr class="memitem:acd13d2ddeca530cb9f26ead47f7d25d3"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classqglviewer_1_1Frame.html#acd13d2ddeca530cb9f26ead47f7d25d3">initFromDOMElement</a> (const QDomElement &element)</td></tr>
222
</table><table class="memberdecls">
223
<tr class="heading"><td colspan="2"><h2><a name="inherited"></a>
224
Additional Inherited Members</h2></td></tr>
224
226
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
225
227
<div class="textblock"><p>The Frame class represents a coordinate system, defined by a position and an orientation. </p>
226
228
<p>A Frame is a 3D coordinate system, represented by a <a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position()</a> and an <a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation()</a>. The order of these transformations is important: the Frame is first translated <em>and</em> <em>then</em> rotated around the new translated origin.</p>
227
229
<p>A Frame is useful to define the position and orientation of a 3D rigid object, using its <a class="el" href="classqglviewer_1_1Frame.html#aa12123cf45f68b9f7fe0526b70ab0047">matrix()</a> method, as shown below: </p>
228
<div class="fragment"><pre class="fragment"> <span class="comment">// Builds a Frame at position (0.5,0,0) and oriented such that its Y axis is along the (1,1,1)</span>
229
<span class="comment">// direction. One could also have used setPosition() and setOrientation().</span>
230
<a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a> fr(Vec(0.5,0,0), Quaternion(Vec(0,1,0), Vec(1,1,1)));
232
glMultMatrixd(fr.matrix());
233
<span class="comment">// Draw your object here, in the local fr coordinate system.</span>
235
</pre></div><p>Many functions are provided to transform a 3D point from one coordinate system (Frame) to an other: see <a class="el" href="classqglviewer_1_1Frame.html#ac706b338b08d9d7b511fd84d0b6ecf96">coordinatesOf()</a>, <a class="el" href="classqglviewer_1_1Frame.html#a5bcb22a3f2e11e42e7469602b75b3c1e">inverseCoordinatesOf()</a>, <a class="el" href="classqglviewer_1_1Frame.html#a8c3c1e66b248a0f29e304e6c786b9391">coordinatesOfIn()</a>, <a class="el" href="classqglviewer_1_1Frame.html#aadad46a46365f6977e4aac6dc18318ce">coordinatesOfFrom()</a>...</p>
230
<div class="fragment"><div class="line"> <span class="comment">// Builds a Frame at position (0.5,0,0) and oriented such that its Y axis is along the (1,1,1)</span></div>
231
<div class="line"> <span class="comment">// direction. One could also have used setPosition() and setOrientation().</span></div>
232
<div class="line"> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a> fr(Vec(0.5,0,0), Quaternion(Vec(0,1,0), Vec(1,1,1)));</div>
233
<div class="line"> glPushMatrix();</div>
234
<div class="line"> glMultMatrixd(fr.matrix());</div>
235
<div class="line"> <span class="comment">// Draw your object here, in the local fr coordinate system.</span></div>
236
<div class="line"> glPopMatrix();</div>
237
</div><!-- fragment --><p>Many functions are provided to transform a 3D point from one coordinate system (Frame) to an other: see <a class="el" href="classqglviewer_1_1Frame.html#ac706b338b08d9d7b511fd84d0b6ecf96">coordinatesOf()</a>, <a class="el" href="classqglviewer_1_1Frame.html#a5bcb22a3f2e11e42e7469602b75b3c1e">inverseCoordinatesOf()</a>, <a class="el" href="classqglviewer_1_1Frame.html#a8c3c1e66b248a0f29e304e6c786b9391">coordinatesOfIn()</a>, <a class="el" href="classqglviewer_1_1Frame.html#aadad46a46365f6977e4aac6dc18318ce">coordinatesOfFrom()</a>...</p>
236
238
<p>You may also want to transform a 3D vector (such as a normal), which corresponds to applying only the rotational part of the frame transformation: see <a class="el" href="classqglviewer_1_1Frame.html#a05a3e18419f02427366a95b1e299f12e">transformOf()</a> and <a class="el" href="classqglviewer_1_1Frame.html#aba2c6c46c1825a81f09d22322b03d9b5">inverseTransformOf()</a>. See the <a href="../examples/frameTransform.html">frameTransform example</a> for an illustration.</p>
237
239
<p>The <a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation()</a> and the <a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation()</a> that are encapsulated in a Frame can also be used to represent a <em>rigid</em> <em>transformation</em> of space. Such a transformation can also be interpreted as a change of coordinate system, and the coordinate system conversion functions actually allow you to use a Frame as a rigid transformation. Use <a class="el" href="classqglviewer_1_1Frame.html#a5bcb22a3f2e11e42e7469602b75b3c1e">inverseCoordinatesOf()</a> (resp. <a class="el" href="classqglviewer_1_1Frame.html#ac706b338b08d9d7b511fd84d0b6ecf96">coordinatesOf()</a>) to apply the transformation (resp. its inverse). Note the inversion.</p>
238
240
<h3>Hierarchy of Frames</h3>
1057
1048
<td></td><td> const</td>
1061
<div class="memdoc">
1051
</div><div class="memdoc">
1062
1052
<p>Fill <code>x</code>, <code>y</code> and <code>z</code> with the <a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation()</a> of the Frame. </p>
1066
<a class="anchor" id="a45358fae434b3912ce81577dc7cf4fc9"></a><!-- doxytag: member="qglviewer::Frame::getWorldMatrix" ref="a45358fae434b3912ce81577dc7cf4fc9" args="(GLdouble m[4][4]) const " -->
1056
<a class="anchor" id="a45358fae434b3912ce81577dc7cf4fc9"></a>
1067
1057
<div class="memitem">
1068
1058
<div class="memproto">
1069
1059
<table class="memname">
1071
<td class="memname">void <a class="el" href="classqglviewer_1_1Frame.html#a45358fae434b3912ce81577dc7cf4fc9">getWorldMatrix</a> </td>
1061
<td class="memname">void getWorldMatrix </td>
1073
1063
<td class="paramtype">GLdouble </td>
1074
1064
<td class="paramname"><em>m</em>[4][4]</td><td>)</td>
1075
1065
<td> const</td>
1079
<div class="memdoc">
1068
</div><div class="memdoc">
1080
1069
<p>float[4][4] parameter version of <a class="el" href="classqglviewer_1_1Frame.html#a39aa0648db05006e2b2f22ac5d971141">worldMatrix()</a>. See also <a class="el" href="classqglviewer_1_1Frame.html#a4915640a54a6b48a99cbdd0cd42fec48">getMatrix()</a> and <a class="el" href="classqglviewer_1_1Frame.html#aa12123cf45f68b9f7fe0526b70ab0047">matrix()</a>. </p>
1084
<a class="anchor" id="ac808850371649942726dd474aba29ead"></a><!-- doxytag: member="qglviewer::Frame::getWorldMatrix" ref="ac808850371649942726dd474aba29ead" args="(GLdouble m[16]) const " -->
1073
<a class="anchor" id="ac808850371649942726dd474aba29ead"></a>
1085
1074
<div class="memitem">
1086
1075
<div class="memproto">
1087
1076
<table class="memname">
1089
<td class="memname">void <a class="el" href="classqglviewer_1_1Frame.html#a45358fae434b3912ce81577dc7cf4fc9">getWorldMatrix</a> </td>
1078
<td class="memname">void getWorldMatrix </td>
1091
1080
<td class="paramtype">GLdouble </td>
1092
1081
<td class="paramname"><em>m</em>[16]</td><td>)</td>
1093
1082
<td> const</td>
1097
<div class="memdoc">
1085
</div><div class="memdoc">
1098
1086
<p>float[16] parameter version of <a class="el" href="classqglviewer_1_1Frame.html#a39aa0648db05006e2b2f22ac5d971141">worldMatrix()</a>. See also <a class="el" href="classqglviewer_1_1Frame.html#a4915640a54a6b48a99cbdd0cd42fec48">getMatrix()</a> and <a class="el" href="classqglviewer_1_1Frame.html#aa12123cf45f68b9f7fe0526b70ab0047">matrix()</a>. </p>
1102
<a class="anchor" id="acd13d2ddeca530cb9f26ead47f7d25d3"></a><!-- doxytag: member="qglviewer::Frame::initFromDOMElement" ref="acd13d2ddeca530cb9f26ead47f7d25d3" args="(const QDomElement &element)" -->
1090
<a class="anchor" id="acd13d2ddeca530cb9f26ead47f7d25d3"></a>
1103
1091
<div class="memitem">
1104
1092
<div class="memproto">
1093
<table class="mlabels">
1095
<td class="mlabels-left">
1105
1096
<table class="memname">
1107
<td class="memname">void <a class="el" href="classqglviewer_1_1Frame.html#acd13d2ddeca530cb9f26ead47f7d25d3">initFromDOMElement</a> </td>
1098
<td class="memname">void initFromDOMElement </td>
1109
1100
<td class="paramtype">const QDomElement & </td>
1110
1101
<td class="paramname"><em>element</em></td><td>)</td>
1111
<td><code> [virtual, slot]</code></td>
1115
<div class="memdoc">
1106
<td class="mlabels-right">
1107
<span class="mlabels"><span class="mlabel">virtual</span><span class="mlabel">slot</span></span> </td>
1110
</div><div class="memdoc">
1116
1111
<p>Restores the Frame state from a <code>QDomElement</code> created by <a class="el" href="classqglviewer_1_1Frame.html#a48e0e2dd26cd96418c8b889ceabe80f6">domElement()</a>.</p>
1117
1112
<p>See <a class="el" href="classqglviewer_1_1Frame.html#a48e0e2dd26cd96418c8b889ceabe80f6">domElement()</a> for the <code>QDomElement</code> syntax. See the <a class="el" href="classqglviewer_1_1Vec.html#acd13d2ddeca530cb9f26ead47f7d25d3">Vec::initFromDOMElement()</a> and <a class="el" href="classqglviewer_1_1Quaternion.html#acd13d2ddeca530cb9f26ead47f7d25d3">Quaternion::initFromDOMElement()</a> documentations for details on default values if an argument is missing.</p>
1118
<dl class="attention"><dt><b>Attention:</b></dt><dd>The <a class="el" href="classqglviewer_1_1Frame.html#a0974dfe336ed84a20adb8c6cdf8dedd9">constraint()</a> and <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> are not restored by this method and are left unchanged. </dd></dl>
1113
<dl class="section attention"><dt>Attention:</dt><dd>The <a class="el" href="classqglviewer_1_1Frame.html#a0974dfe336ed84a20adb8c6cdf8dedd9">constraint()</a> and <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> are not restored by this method and are left unchanged. </dd></dl>
1120
1115
<p>Reimplemented in <a class="el" href="classqglviewer_1_1ManipulatedFrame.html#acd13d2ddeca530cb9f26ead47f7d25d3">ManipulatedFrame</a>, and <a class="el" href="classqglviewer_1_1ManipulatedCameraFrame.html#acd13d2ddeca530cb9f26ead47f7d25d3">ManipulatedCameraFrame</a>.</p>
1124
<a class="anchor" id="ab55c2a4f1732b90057fae4b6037399de"></a><!-- doxytag: member="qglviewer::Frame::interpolated" ref="ab55c2a4f1732b90057fae4b6037399de" args="()" -->
1119
<a class="anchor" id="ab55c2a4f1732b90057fae4b6037399de"></a>
1125
1120
<div class="memitem">
1126
1121
<div class="memproto">
1122
<table class="mlabels">
1124
<td class="mlabels-left">
1127
1125
<table class="memname">
1129
<td class="memname">void <a class="el" href="classqglviewer_1_1Frame.html#ab55c2a4f1732b90057fae4b6037399de">interpolated</a> </td>
1127
<td class="memname">void interpolated </td>
1131
1129
<td class="paramname"></td><td>)</td>
1132
<td><code> [signal]</code></td>
1136
<div class="memdoc">
1134
<td class="mlabels-right">
1135
<span class="mlabels"><span class="mlabel">signal</span></span> </td>
1138
</div><div class="memdoc">
1137
1139
<p>This signal is emitted when the Frame is interpolated by a <a class="el" href="classqglviewer_1_1KeyFrameInterpolator.html" title="A keyFrame Catmull-Rom Frame interpolator.">KeyFrameInterpolator</a>.</p>
1138
1140
<p>See the <a class="el" href="classqglviewer_1_1KeyFrameInterpolator.html" title="A keyFrame Catmull-Rom Frame interpolator.">KeyFrameInterpolator</a> documentation for details.</p>
1139
1141
<p>If a <a class="el" href="classqglviewer_1_1KeyFrameInterpolator.html" title="A keyFrame Catmull-Rom Frame interpolator.">KeyFrameInterpolator</a> is used to successively interpolate several Frames in your scene, connect the <a class="el" href="classqglviewer_1_1KeyFrameInterpolator.html#ab55c2a4f1732b90057fae4b6037399de">KeyFrameInterpolator::interpolated()</a> signal instead (identical, but independent of the interpolated Frame). </p>
1143
<a class="anchor" id="a4534c3188c217feb8d21465d4cefd4ad"></a><!-- doxytag: member="qglviewer::Frame::inverse" ref="a4534c3188c217feb8d21465d4cefd4ad" args="() const " -->
1145
<a class="anchor" id="a4534c3188c217feb8d21465d4cefd4ad"></a>
1144
1146
<div class="memitem">
1145
1147
<div class="memproto">
1146
1148
<table class="memname">
1148
<td class="memname">Frame <a class="el" href="classqglviewer_1_1Frame.html#a4534c3188c217feb8d21465d4cefd4ad">inverse</a> </td>
1150
<td class="memname">Frame inverse </td>
1150
1152
<td class="paramname"></td><td>)</td>
1151
1153
<td> const</td>
1155
<div class="memdoc">
1156
</div><div class="memdoc">
1156
1157
<p>Returns a Frame representing the inverse of the Frame space transformation.</p>
1157
1158
<p>The <a class="el" href="classqglviewer_1_1Frame.html#a19ee9243c60f412dfc4eac3dcf45a5a1">rotation()</a> of the new Frame is the <a class="el" href="classqglviewer_1_1Quaternion.html#ac378ebc684d691dc25336b895f24a82e">Quaternion::inverse()</a> of the original rotation. Its <a class="el" href="classqglviewer_1_1Frame.html#a388a5f38140104323aa51fc207fde642">translation()</a> is the negated inverse rotated image of the original translation.</p>
1158
1159
<p>If a Frame is considered as a space rigid transformation (translation and rotation), the <a class="el" href="classqglviewer_1_1Frame.html#a4534c3188c217feb8d21465d4cefd4ad">inverse()</a> Frame performs the inverse transformation.</p>
1159
1160
<p>Only the local Frame transformation (i.e. defined with respect to the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a>) is inverted. Use <a class="el" href="classqglviewer_1_1Frame.html#a37d4da8cfd297273e7bb55538debaa3e">worldInverse()</a> for a global inverse.</p>
1160
1161
<p>The resulting Frame has the same <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> as the Frame and a <code>NULL</code> <a class="el" href="classqglviewer_1_1Frame.html#a0974dfe336ed84a20adb8c6cdf8dedd9">constraint()</a>.</p>
1161
<dl class="note"><dt><b>Note:</b></dt><dd>The scaling factor of the 4x4 matrix is 1.0. </dd></dl>
1162
<dl class="section note"><dt>Note:</dt><dd>The scaling factor of the 4x4 matrix is 1.0. </dd></dl>
1165
<a class="anchor" id="a5bcb22a3f2e11e42e7469602b75b3c1e"></a><!-- doxytag: member="qglviewer::Frame::inverseCoordinatesOf" ref="a5bcb22a3f2e11e42e7469602b75b3c1e" args="(const Vec &src) const " -->
1166
<a class="anchor" id="a5bcb22a3f2e11e42e7469602b75b3c1e"></a>
1166
1167
<div class="memitem">
1167
1168
<div class="memproto">
1168
1169
<table class="memname">
1170
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> <a class="el" href="classqglviewer_1_1Frame.html#a5bcb22a3f2e11e42e7469602b75b3c1e">inverseCoordinatesOf</a> </td>
1171
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> inverseCoordinatesOf </td>
1172
1173
<td class="paramtype">const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> & </td>
1173
1174
<td class="paramname"><em>src</em></td><td>)</td>
1174
1175
<td> const</td>
1178
<div class="memdoc">
1178
</div><div class="memdoc">
1179
1179
<p>Returns the world coordinates of the point whose position in the Frame coordinate system is <code>src</code> (converts from Frame to world).</p>
1180
1180
<p><a class="el" href="classqglviewer_1_1Frame.html#ac706b338b08d9d7b511fd84d0b6ecf96">coordinatesOf()</a> performs the inverse convertion. Use <a class="el" href="classqglviewer_1_1Frame.html#aba2c6c46c1825a81f09d22322b03d9b5">inverseTransformOf()</a> to transform 3D vectors instead of 3D coordinates. </p>
1184
<a class="anchor" id="aba2c6c46c1825a81f09d22322b03d9b5"></a><!-- doxytag: member="qglviewer::Frame::inverseTransformOf" ref="aba2c6c46c1825a81f09d22322b03d9b5" args="(const Vec &src) const " -->
1184
<a class="anchor" id="aba2c6c46c1825a81f09d22322b03d9b5"></a>
1185
1185
<div class="memitem">
1186
1186
<div class="memproto">
1187
1187
<table class="memname">
1189
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> <a class="el" href="classqglviewer_1_1Frame.html#aba2c6c46c1825a81f09d22322b03d9b5">inverseTransformOf</a> </td>
1189
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> inverseTransformOf </td>
1191
1191
<td class="paramtype">const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> & </td>
1192
1192
<td class="paramname"><em>src</em></td><td>)</td>
1193
1193
<td> const</td>
1197
<div class="memdoc">
1196
</div><div class="memdoc">
1198
1197
<p>Returns the world transform of the vector whose coordinates in the Frame coordinate system is <code>src</code> (converts vectors from Frame to world).</p>
1199
1198
<p><a class="el" href="classqglviewer_1_1Frame.html#a05a3e18419f02427366a95b1e299f12e">transformOf()</a> performs the inverse transformation. Use <a class="el" href="classqglviewer_1_1Frame.html#a5bcb22a3f2e11e42e7469602b75b3c1e">inverseCoordinatesOf()</a> to transform 3D coordinates instead of 3D vectors. </p>
1203
<a class="anchor" id="a2b113688a0cab6c439dfbf598fd45e70"></a><!-- doxytag: member="qglviewer::Frame::localCoordinatesOf" ref="a2b113688a0cab6c439dfbf598fd45e70" args="(const Vec &src) const " -->
1202
<a class="anchor" id="a2b113688a0cab6c439dfbf598fd45e70"></a>
1204
1203
<div class="memitem">
1205
1204
<div class="memproto">
1206
1205
<table class="memname">
1208
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> <a class="el" href="classqglviewer_1_1Frame.html#a2b113688a0cab6c439dfbf598fd45e70">localCoordinatesOf</a> </td>
1207
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> localCoordinatesOf </td>
1210
1209
<td class="paramtype">const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> & </td>
1211
1210
<td class="paramname"><em>src</em></td><td>)</td>
1212
1211
<td> const</td>
1216
<div class="memdoc">
1214
</div><div class="memdoc">
1217
1215
<p>Returns the Frame coordinates of a point <code>src</code> defined in the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> coordinate system (converts from <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> to Frame).</p>
1218
1216
<p><a class="el" href="classqglviewer_1_1Frame.html#a4e6ac1c504a2f70fdbc0e7383c1aa7c7">localInverseCoordinatesOf()</a> performs the inverse convertion. See also <a class="el" href="classqglviewer_1_1Frame.html#a37239448835f46771b9598a31b964cf2">localTransformOf()</a>. </p>
1222
<a class="anchor" id="a4e6ac1c504a2f70fdbc0e7383c1aa7c7"></a><!-- doxytag: member="qglviewer::Frame::localInverseCoordinatesOf" ref="a4e6ac1c504a2f70fdbc0e7383c1aa7c7" args="(const Vec &src) const " -->
1220
<a class="anchor" id="a4e6ac1c504a2f70fdbc0e7383c1aa7c7"></a>
1223
1221
<div class="memitem">
1224
1222
<div class="memproto">
1225
1223
<table class="memname">
1227
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> <a class="el" href="classqglviewer_1_1Frame.html#a4e6ac1c504a2f70fdbc0e7383c1aa7c7">localInverseCoordinatesOf</a> </td>
1225
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> localInverseCoordinatesOf </td>
1229
1227
<td class="paramtype">const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> & </td>
1230
1228
<td class="paramname"><em>src</em></td><td>)</td>
1231
1229
<td> const</td>
1235
<div class="memdoc">
1232
</div><div class="memdoc">
1236
1233
<p>Returns the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> coordinates of a point <code>src</code> defined in the Frame coordinate system (converts from Frame to <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a>).</p>
1237
1234
<p><a class="el" href="classqglviewer_1_1Frame.html#a2b113688a0cab6c439dfbf598fd45e70">localCoordinatesOf()</a> performs the inverse convertion. See also <a class="el" href="classqglviewer_1_1Frame.html#ad36cf320ff7cf6c8f9a2ac527c924f9e">localInverseTransformOf()</a>. </p>
1241
<a class="anchor" id="ad36cf320ff7cf6c8f9a2ac527c924f9e"></a><!-- doxytag: member="qglviewer::Frame::localInverseTransformOf" ref="ad36cf320ff7cf6c8f9a2ac527c924f9e" args="(const Vec &src) const " -->
1238
<a class="anchor" id="ad36cf320ff7cf6c8f9a2ac527c924f9e"></a>
1242
1239
<div class="memitem">
1243
1240
<div class="memproto">
1244
1241
<table class="memname">
1246
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> <a class="el" href="classqglviewer_1_1Frame.html#ad36cf320ff7cf6c8f9a2ac527c924f9e">localInverseTransformOf</a> </td>
1243
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> localInverseTransformOf </td>
1248
1245
<td class="paramtype">const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> & </td>
1249
1246
<td class="paramname"><em>src</em></td><td>)</td>
1250
1247
<td> const</td>
1254
<div class="memdoc">
1250
</div><div class="memdoc">
1255
1251
<p>Returns the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> transform of a vector <code>src</code> defined in the Frame coordinate system (converts vectors from Frame to <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a>).</p>
1256
1252
<p><a class="el" href="classqglviewer_1_1Frame.html#a37239448835f46771b9598a31b964cf2">localTransformOf()</a> performs the inverse transformation. See also <a class="el" href="classqglviewer_1_1Frame.html#a4e6ac1c504a2f70fdbc0e7383c1aa7c7">localInverseCoordinatesOf()</a>. </p>
1260
<a class="anchor" id="a37239448835f46771b9598a31b964cf2"></a><!-- doxytag: member="qglviewer::Frame::localTransformOf" ref="a37239448835f46771b9598a31b964cf2" args="(const Vec &src) const " -->
1256
<a class="anchor" id="a37239448835f46771b9598a31b964cf2"></a>
1261
1257
<div class="memitem">
1262
1258
<div class="memproto">
1263
1259
<table class="memname">
1265
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> <a class="el" href="classqglviewer_1_1Frame.html#a37239448835f46771b9598a31b964cf2">localTransformOf</a> </td>
1261
<td class="memname"><a class="el" href="classqglviewer_1_1Vec.html">Vec</a> localTransformOf </td>
1267
1263
<td class="paramtype">const <a class="el" href="classqglviewer_1_1Vec.html">Vec</a> & </td>
1268
1264
<td class="paramname"><em>src</em></td><td>)</td>
1269
1265
<td> const</td>
1273
<div class="memdoc">
1268
</div><div class="memdoc">
1274
1269
<p>Returns the Frame transform of a vector <code>src</code> defined in the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> coordinate system (converts vectors from <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> to Frame).</p>
1275
1270
<p><a class="el" href="classqglviewer_1_1Frame.html#ad36cf320ff7cf6c8f9a2ac527c924f9e">localInverseTransformOf()</a> performs the inverse transformation. See also <a class="el" href="classqglviewer_1_1Frame.html#a2b113688a0cab6c439dfbf598fd45e70">localCoordinatesOf()</a>. </p>
1279
<a class="anchor" id="aa12123cf45f68b9f7fe0526b70ab0047"></a><!-- doxytag: member="qglviewer::Frame::matrix" ref="aa12123cf45f68b9f7fe0526b70ab0047" args="() const " -->
1274
<a class="anchor" id="aa12123cf45f68b9f7fe0526b70ab0047"></a>
1280
1275
<div class="memitem">
1281
1276
<div class="memproto">
1282
1277
<table class="memname">
1284
<td class="memname">const GLdouble * <a class="el" href="classqglviewer_1_1Frame.html#aa12123cf45f68b9f7fe0526b70ab0047">matrix</a> </td>
1279
<td class="memname">const GLdouble * matrix </td>
1286
1281
<td class="paramname"></td><td>)</td>
1287
1282
<td> const</td>
1291
<div class="memdoc">
1285
</div><div class="memdoc">
1292
1286
<p>Returns the 4x4 OpenGL transformation matrix represented by the Frame.</p>
1293
1287
<p>This method should be used in conjunction with <code>glMultMatrixd()</code> to modify the OpenGL modelview matrix from a Frame hierarchy. With this Frame hierarchy: </p>
1294
<div class="fragment"><pre class="fragment"> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>* body = <span class="keyword">new</span> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>();
1295
<a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>* leftArm = <span class="keyword">new</span> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>();
1296
<a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>* rightArm = <span class="keyword">new</span> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>();
1297
leftArm->setReferenceFrame(body);
1298
rightArm->setReferenceFrame(body);
1299
</pre></div><p>The associated OpenGL drawing code should look like: </p>
1300
<div class="fragment"><pre class="fragment"> <span class="keywordtype">void</span> Viewer::draw()
1303
glMultMatrixd(body->matrix());
1307
glMultMatrixd(leftArm->matrix());
1312
glMultMatrixd(rightArm->matrix());
1318
</pre></div><p> Note the use of nested <code>glPushMatrix()</code> and <code>glPopMatrix()</code> blocks to represent the frame hierarchy: <code>leftArm</code> and <code>rightArm</code> are both correctly drawn with respect to the <code>body</code> coordinate system.</p>
1288
<div class="fragment"><div class="line"> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>* body = <span class="keyword">new</span> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>();</div>
1289
<div class="line"> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>* leftArm = <span class="keyword">new</span> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>();</div>
1290
<div class="line"> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>* rightArm = <span class="keyword">new</span> <a class="code" href="classqglviewer_1_1Frame.html#ab71e6ee46f0c2593266f9a62d9c5e029">Frame</a>();</div>
1291
<div class="line"> leftArm->setReferenceFrame(body);</div>
1292
<div class="line"> rightArm->setReferenceFrame(body);</div>
1293
</div><!-- fragment --><p>The associated OpenGL drawing code should look like: </p>
1294
<div class="fragment"><div class="line"> <span class="keywordtype">void</span> Viewer::draw()</div>
1295
<div class="line"> {</div>
1296
<div class="line"> glPushMatrix();</div>
1297
<div class="line"> glMultMatrixd(body->matrix());</div>
1298
<div class="line"> drawBody();</div>
1299
<div class="line"></div>
1300
<div class="line"> glPushMatrix();</div>
1301
<div class="line"> glMultMatrixd(leftArm->matrix());</div>
1302
<div class="line"> drawArm();</div>
1303
<div class="line"> glPopMatrix();</div>
1304
<div class="line"></div>
1305
<div class="line"> glPushMatrix();</div>
1306
<div class="line"> glMultMatrixd(rightArm->matrix());</div>
1307
<div class="line"> drawArm();</div>
1308
<div class="line"> glPopMatrix();</div>
1309
<div class="line"></div>
1310
<div class="line"> glPopMatrix();</div>
1311
<div class="line"> }</div>
1312
</div><!-- fragment --><p> Note the use of nested <code>glPushMatrix()</code> and <code>glPopMatrix()</code> blocks to represent the frame hierarchy: <code>leftArm</code> and <code>rightArm</code> are both correctly drawn with respect to the <code>body</code> coordinate system.</p>
1319
1313
<p>This matrix only represents the local Frame transformation (i.e. with respect to the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a>). Use <a class="el" href="classqglviewer_1_1Frame.html#a39aa0648db05006e2b2f22ac5d971141">worldMatrix()</a> to get the full Frame transformation matrix (i.e. from the world to the Frame coordinate system). These two match when the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> is <code>NULL</code>.</p>
1320
1314
<p>The result is only valid until the next call to <a class="el" href="classqglviewer_1_1Frame.html#aa12123cf45f68b9f7fe0526b70ab0047">matrix()</a>, <a class="el" href="classqglviewer_1_1Frame.html#a4915640a54a6b48a99cbdd0cd42fec48">getMatrix()</a>, <a class="el" href="classqglviewer_1_1Frame.html#a39aa0648db05006e2b2f22ac5d971141">worldMatrix()</a> or <a class="el" href="classqglviewer_1_1Frame.html#a45358fae434b3912ce81577dc7cf4fc9">getWorldMatrix()</a>. Use it immediately (as above) or use <a class="el" href="classqglviewer_1_1Frame.html#a4915640a54a6b48a99cbdd0cd42fec48">getMatrix()</a> instead.</p>
1321
<dl class="attention"><dt><b>Attention:</b></dt><dd>The OpenGL format of the result is the transpose of the actual mathematical European representation (translation is on the last <em>line</em> instead of the last <em>column</em>).</dd></dl>
1322
<dl class="note"><dt><b>Note:</b></dt><dd>The scaling factor of the 4x4 matrix is 1.0. </dd></dl>
1315
<dl class="section attention"><dt>Attention:</dt><dd>The OpenGL format of the result is the transpose of the actual mathematical European representation (translation is on the last <em>line</em> instead of the last <em>column</em>).</dd></dl>
1316
<dl class="section note"><dt>Note:</dt><dd>The scaling factor of the 4x4 matrix is 1.0. </dd></dl>
1326
<a class="anchor" id="ab6722375e68e03d151762ebfc83c5459"></a><!-- doxytag: member="qglviewer::Frame::modified" ref="ab6722375e68e03d151762ebfc83c5459" args="()" -->
1320
<a class="anchor" id="ab6722375e68e03d151762ebfc83c5459"></a>
1327
1321
<div class="memitem">
1328
1322
<div class="memproto">
1323
<table class="mlabels">
1325
<td class="mlabels-left">
1329
1326
<table class="memname">
1331
<td class="memname">void <a class="el" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a> </td>
1328
<td class="memname">void modified </td>
1333
1330
<td class="paramname"></td><td>)</td>
1334
<td><code> [signal]</code></td>
1338
<div class="memdoc">
1335
<td class="mlabels-right">
1336
<span class="mlabels"><span class="mlabel">signal</span></span> </td>
1339
</div><div class="memdoc">
1339
1340
<p>This signal is emitted whenever the <a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position()</a> or the <a class="el" href="classqglviewer_1_1Frame.html#a691af39b54669fad8b4e73599de22094">orientation()</a> of the Frame is modified.</p>
1340
1341
<p>Connect this signal to any object that must be notified: </p>
1341
<div class="fragment"><pre class="fragment"> QObject::connect(myFrame, SIGNAL(<a class="code" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a>()), myObject, SLOT(update()));
1342
</pre></div><p> Use the <a class="el" href="classQGLViewer.html#a32d7a506084c50fd97a24f94d9ca4864">QGLViewer::QGLViewerPool()</a> to connect the signal to all the viewers.</p>
1343
<dl class="note"><dt><b>Note:</b></dt><dd>If your Frame is part of a Frame hierarchy (see <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a>), a modification of one of the parents of this Frame will <em>not</em> emit this signal. Use code like this to change this behavior (you can do this recursively for all the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> until the <code>NULL</code> world root frame is encountered): <div class="fragment"><pre class="fragment"> <span class="comment">// Emits the Frame modified() signal when its referenceFrame() is modified().</span>
1344
connect(myFrame->referenceFrame(), SIGNAL(<a class="code" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a>()), myFrame, SIGNAL(<a class="code" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a>()));
1345
</pre></div></dd></dl>
1346
<dl class="attention"><dt><b>Attention:</b></dt><dd>Connecting this signal to a QGLWidget::updateGL() slot (or a method that calls it) will prevent you from modifying the Frame <em>inside</em> your <a class="el" href="classQGLViewer.html#abc45d04e5f5ce1fbd68f920fcdb2d0e0">QGLViewer::draw()</a> method as it would result in an infinite loop. However, <a class="el" href="classQGLViewer.html#abc45d04e5f5ce1fbd68f920fcdb2d0e0">QGLViewer::draw()</a> should not modify the scene.</dd></dl>
1347
<dl class="note"><dt><b>Note:</b></dt><dd>For efficiency reasons, this signal is emitted even if the Frame is not actually modified, for instance with translate(Vec(0,0,0)) or setPosition(<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position()</a>). </dd></dl>
1342
<div class="fragment"><div class="line"> QObject::connect(myFrame, SIGNAL(<a class="code" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a>()), myObject, SLOT(update()));</div>
1343
</div><!-- fragment --><p> Use the <a class="el" href="classQGLViewer.html#a32d7a506084c50fd97a24f94d9ca4864">QGLViewer::QGLViewerPool()</a> to connect the signal to all the viewers.</p>
1344
<dl class="section note"><dt>Note:</dt><dd>If your Frame is part of a Frame hierarchy (see <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a>), a modification of one of the parents of this Frame will <em>not</em> emit this signal. Use code like this to change this behavior (you can do this recursively for all the <a class="el" href="classqglviewer_1_1Frame.html#a9794b079db5f492e8804631d3d23baec">referenceFrame()</a> until the <code>NULL</code> world root frame is encountered): <div class="fragment"><div class="line"> <span class="comment">// Emits the Frame modified() signal when its referenceFrame() is modified().</span></div>
1345
<div class="line"> connect(myFrame->referenceFrame(), SIGNAL(<a class="code" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a>()), myFrame, SIGNAL(<a class="code" href="classqglviewer_1_1Frame.html#ab6722375e68e03d151762ebfc83c5459">modified</a>()));</div>
1346
</div><!-- fragment --></dd></dl>
1347
<dl class="section attention"><dt>Attention:</dt><dd>Connecting this signal to a QGLWidget::updateGL() slot (or a method that calls it) will prevent you from modifying the Frame <em>inside</em> your <a class="el" href="classQGLViewer.html#abc45d04e5f5ce1fbd68f920fcdb2d0e0">QGLViewer::draw()</a> method as it would result in an infinite loop. However, <a class="el" href="classQGLViewer.html#abc45d04e5f5ce1fbd68f920fcdb2d0e0">QGLViewer::draw()</a> should not modify the scene.</dd></dl>
1348
<dl class="section note"><dt>Note:</dt><dd>For efficiency reasons, this signal is emitted even if the Frame is not actually modified, for instance with translate(Vec(0,0,0)) or setPosition(<a class="el" href="classqglviewer_1_1Frame.html#abc38a05a597e07c9ff525122682adc50">position()</a>). </dd></dl>
1351
<a class="anchor" id="aeb0f5ceffbb62f990b89b200d6ce728c"></a><!-- doxytag: member="qglviewer::Frame::operator=" ref="aeb0f5ceffbb62f990b89b200d6ce728c" args="(const Frame &frame)" -->
1352
<a class="anchor" id="aeb0f5ceffbb62f990b89b200d6ce728c"></a>
1352
1353
<div class="memitem">
1353
1354
<div class="memproto">
1354
1355
<table class="memname">