_collide_shape_vs_shape_per_leaf_8h_source.html 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
  5. <meta http-equiv="X-UA-Compatible" content="IE=11"/>
  6. <meta name="generator" content="Doxygen 1.12.0"/>
  7. <meta name="viewport" content="width=device-width, initial-scale=1"/>
  8. <title>Jolt Physics: Jolt/Physics/Collision/CollideShapeVsShapePerLeaf.h Source File</title>
  9. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  10. <script type="text/javascript" src="jquery.js"></script>
  11. <script type="text/javascript" src="dynsections.js"></script>
  12. <script type="text/javascript" src="clipboard.js"></script>
  13. <link href="navtree.css" rel="stylesheet" type="text/css"/>
  14. <script type="text/javascript" src="navtreedata.js"></script>
  15. <script type="text/javascript" src="navtree.js"></script>
  16. <script type="text/javascript" src="resize.js"></script>
  17. <script type="text/javascript" src="cookie.js"></script>
  18. <link href="search/search.css" rel="stylesheet" type="text/css"/>
  19. <script type="text/javascript" src="search/searchdata.js"></script>
  20. <script type="text/javascript" src="search/search.js"></script>
  21. <script type="text/x-mathjax-config">
  22. MathJax.Hub.Config({
  23. extensions: ["tex2jax.js"],
  24. jax: ["input/TeX","output/HTML-CSS"],
  25. });
  26. </script>
  27. <script type="text/javascript" async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js"></script>
  28. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  29. </head>
  30. <body>
  31. <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
  32. <div id="titlearea">
  33. <table cellspacing="0" cellpadding="0">
  34. <tbody>
  35. <tr id="projectrow">
  36. <td id="projectlogo"><img alt="Logo" src="LogoSmall.png"/></td>
  37. <td id="projectalign">
  38. <div id="projectname">Jolt Physics
  39. </div>
  40. <div id="projectbrief">A multi core friendly Game Physics Engine</div>
  41. </td>
  42. </tr>
  43. </tbody>
  44. </table>
  45. </div>
  46. <!-- end header part -->
  47. <!-- Generated by Doxygen 1.12.0 -->
  48. <script type="text/javascript">
  49. /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
  50. var searchBox = new SearchBox("searchBox", "search/",'.html');
  51. /* @license-end */
  52. </script>
  53. <script type="text/javascript">
  54. /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
  55. $(function() { codefold.init(0); });
  56. /* @license-end */
  57. </script>
  58. <script type="text/javascript" src="menudata.js"></script>
  59. <script type="text/javascript" src="menu.js"></script>
  60. <script type="text/javascript">
  61. /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
  62. $(function() {
  63. initMenu('',true,false,'search.php','Search',true);
  64. $(function() { init_search(); });
  65. });
  66. /* @license-end */
  67. </script>
  68. <div id="main-nav"></div>
  69. </div><!-- top -->
  70. <div id="side-nav" class="ui-resizable side-nav-resizable">
  71. <div id="nav-tree">
  72. <div id="nav-tree-contents">
  73. <div id="nav-sync" class="sync"></div>
  74. </div>
  75. </div>
  76. <div id="splitbar" style="-moz-user-select:none;"
  77. class="ui-resizable-handle">
  78. </div>
  79. </div>
  80. <script type="text/javascript">
  81. /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
  82. $(function(){initNavTree('_collide_shape_vs_shape_per_leaf_8h_source.html',''); initResizable(true); });
  83. /* @license-end */
  84. </script>
  85. <div id="doc-content">
  86. <!-- window showing the filter options -->
  87. <div id="MSearchSelectWindow"
  88. onmouseover="return searchBox.OnSearchSelectShow()"
  89. onmouseout="return searchBox.OnSearchSelectHide()"
  90. onkeydown="return searchBox.OnSearchSelectKey(event)">
  91. </div>
  92. <!-- iframe showing the search results (closed by default) -->
  93. <div id="MSearchResultsWindow">
  94. <div id="MSearchResults">
  95. <div class="SRPage">
  96. <div id="SRIndex">
  97. <div id="SRResults"></div>
  98. <div class="SRStatus" id="Loading">Loading...</div>
  99. <div class="SRStatus" id="Searching">Searching...</div>
  100. <div class="SRStatus" id="NoMatches">No Matches</div>
  101. </div>
  102. </div>
  103. </div>
  104. </div>
  105. <div class="header">
  106. <div class="headertitle"><div class="title">CollideShapeVsShapePerLeaf.h</div></div>
  107. </div><!--header-->
  108. <div class="contents">
  109. <a href="_collide_shape_vs_shape_per_leaf_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="comment">// Jolt Physics Library (https://github.com/jrouwe/JoltPhysics)</span></div>
  110. <div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="comment">// SPDX-FileCopyrightText: 2025 Jorrit Rouwe</span></div>
  111. <div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span><span class="comment">// SPDX-License-Identifier: MIT</span></div>
  112. <div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span> </div>
  113. <div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span><span class="preprocessor">#pragma once</span></div>
  114. <div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> </div>
  115. <div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span><span class="preprocessor">#include &lt;<a class="code" href="_collide_shape_8h.html">Jolt/Physics/Collision/CollideShape.h</a>&gt;</span></div>
  116. <div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span><span class="preprocessor">#include &lt;<a class="code" href="_collision_dispatch_8h.html">Jolt/Physics/Collision/CollisionDispatch.h</a>&gt;</span></div>
  117. <div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span><span class="preprocessor">#include &lt;<a class="code" href="_transformed_shape_8h.html">Jolt/Physics/Collision/TransformedShape.h</a>&gt;</span></div>
  118. <div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span><span class="preprocessor">#include &lt;<a class="code" href="_s_t_l_local_allocator_8h.html">Jolt/Core/STLLocalAllocator.h</a>&gt;</span></div>
  119. <div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> </div>
  120. <div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span><a class="code hl_define" href="_core_8h.html#ad14098b68b8c44ea6112601031268405">JPH_NAMESPACE_BEGIN</a></div>
  121. <div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> </div>
  122. <div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span><span class="keyword">template</span> &lt;<span class="keyword">class</span> LeafCollector&gt;</div>
  123. <div class="foldopen" id="foldopen00030" data-start="{" data-end="}">
  124. <div class="line"><a id="l00030" name="l00030"></a><span class="lineno"><a class="line" href="_collide_shape_vs_shape_per_leaf_8h.html#a78921979ac4a2f3e4d5b6ded9cea4d3d"> 30</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="_collide_shape_vs_shape_per_leaf_8h.html#a78921979ac4a2f3e4d5b6ded9cea4d3d">CollideShapeVsShapePerLeaf</a>(<span class="keyword">const</span> <a class="code hl_class" href="class_shape.html">Shape</a> *inShape1, <span class="keyword">const</span> <a class="code hl_class" href="class_shape.html">Shape</a> *inShape2, <a class="code hl_class" href="class_vec3.html">Vec3Arg</a> inScale1, <a class="code hl_class" href="class_vec3.html">Vec3Arg</a> inScale2, <a class="code hl_class" href="class_mat44.html">Mat44Arg</a> inCenterOfMassTransform1, <a class="code hl_class" href="class_mat44.html">Mat44Arg</a> inCenterOfMassTransform2, <span class="keyword">const</span> <a class="code hl_class" href="class_sub_shape_i_d_creator.html">SubShapeIDCreator</a> &amp;inSubShapeIDCreator1, <span class="keyword">const</span> <a class="code hl_class" href="class_sub_shape_i_d_creator.html">SubShapeIDCreator</a> &amp;inSubShapeIDCreator2, <span class="keyword">const</span> <a class="code hl_class" href="class_collide_shape_settings.html">CollideShapeSettings</a> &amp;inCollideShapeSettings, <a class="code hl_class" href="class_collision_collector.html">CollideShapeCollector</a> &amp;ioCollector, <span class="keyword">const</span> <a class="code hl_class" href="class_shape_filter.html">ShapeFilter</a> &amp;inShapeFilter = { })</div>
  125. <div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span>{</div>
  126. <div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> <span class="comment">// Tracks information we need about a leaf shape</span></div>
  127. <div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> <span class="keyword">struct </span>LeafShape</div>
  128. <div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> {</div>
  129. <div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> LeafShape() = <span class="keywordflow">default</span>;</div>
  130. <div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> </div>
  131. <div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> LeafShape(<span class="keyword">const</span> <a class="code hl_class" href="class_a_a_box.html">AABox</a> &amp;inBounds, <a class="code hl_class" href="class_mat44.html">Mat44Arg</a> inCenterOfMassTransform, <a class="code hl_class" href="class_vec3.html">Vec3Arg</a> inScale, <span class="keyword">const</span> <a class="code hl_class" href="class_shape.html">Shape</a> *inShape, <span class="keyword">const</span> <a class="code hl_class" href="class_sub_shape_i_d_creator.html">SubShapeIDCreator</a> &amp;inSubShapeIDCreator) :</div>
  132. <div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> mBounds(inBounds),</div>
  133. <div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> mCenterOfMassTransform(inCenterOfMassTransform),</div>
  134. <div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> mScale(inScale),</div>
  135. <div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> mShape(inShape),</div>
  136. <div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> mSubShapeIDCreator(inSubShapeIDCreator)</div>
  137. <div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> {</div>
  138. <div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> }</div>
  139. <div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> </div>
  140. <div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> <a class="code hl_class" href="class_a_a_box.html">AABox</a> mBounds;</div>
  141. <div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> <a class="code hl_class" href="class_mat44.html">Mat44</a> mCenterOfMassTransform;</div>
  142. <div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> <a class="code hl_class" href="class_vec3.html">Vec3</a> mScale;</div>
  143. <div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> <span class="keyword">const</span> <a class="code hl_class" href="class_shape.html">Shape</a> * mShape;</div>
  144. <div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span> <a class="code hl_class" href="class_sub_shape_i_d_creator.html">SubShapeIDCreator</a> mSubShapeIDCreator;</div>
  145. <div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> };</div>
  146. <div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span> </div>
  147. <div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> <span class="keyword">constexpr</span> <a class="code hl_typedef" href="_core_8h.html#a69aa29b598b851b0640aa225a9e5d61d">uint</a> cMaxLocalLeafShapes = 32;</div>
  148. <div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> </div>
  149. <div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span> <span class="comment">// A collector that stores the information we need from a leaf shape in an array that is usually on the stack but can fall back to the heap if needed</span></div>
  150. <div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span> <span class="keyword">class </span>MyCollector : <span class="keyword">public</span> <a class="code hl_class" href="class_collision_collector.html">TransformedShapeCollector</a></div>
  151. <div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> {</div>
  152. <div class="line"><a id="l00058" name="l00058"></a><span class="lineno"> 58</span> <span class="keyword">public</span>:</div>
  153. <div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span> MyCollector()</div>
  154. <div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> {</div>
  155. <div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> mHits.reserve(cMaxLocalLeafShapes);</div>
  156. <div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> }</div>
  157. <div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> </div>
  158. <div class="line"><a id="l00064" name="l00064"></a><span class="lineno"> 64</span> <span class="keywordtype">void</span> <a class="code hl_function" href="class_collision_collector.html#a762c35402676662897e50dd8224e496e">AddHit</a>(<span class="keyword">const</span> <a class="code hl_class" href="class_transformed_shape.html">TransformedShape</a> &amp;inShape)<span class="keyword"> override</span></div>
  159. <div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span><span class="keyword"> </span>{</div>
  160. <div class="line"><a id="l00066" name="l00066"></a><span class="lineno"> 66</span> mHits.emplace_back(inShape.<a class="code hl_function" href="class_transformed_shape.html#a33b12d09ebaf2071dd49a3873978ac0a">GetWorldSpaceBounds</a>(), inShape.<a class="code hl_function" href="class_transformed_shape.html#afba760db30ccff8c59547cce78bd97a4">GetCenterOfMassTransform</a>().<a class="code hl_function" href="class_mat44.html#a3445a728646fe8ad80381a0e55ea2289">ToMat44</a>(), inShape.<a class="code hl_function" href="class_transformed_shape.html#a9f0559c4106b9b17becd5f401389b354">GetShapeScale</a>(), inShape.<a class="code hl_variable" href="class_transformed_shape.html#ac6aaf976fee41c402c791012e4a2a3f9">mShape</a>, inShape.<a class="code hl_variable" href="class_transformed_shape.html#a3d0b38db0aacff1c3188a0c20f45e713">mSubShapeIDCreator</a>);</div>
  161. <div class="line"><a id="l00067" name="l00067"></a><span class="lineno"> 67</span> }</div>
  162. <div class="line"><a id="l00068" name="l00068"></a><span class="lineno"> 68</span> </div>
  163. <div class="line"><a id="l00069" name="l00069"></a><span class="lineno"> 69</span> <a class="code hl_class" href="class_array.html">Array&lt;LeafShape, STLLocalAllocator&lt;LeafShape, cMaxLocalLeafShapes&gt;</a>&gt; mHits;</div>
  164. <div class="line"><a id="l00070" name="l00070"></a><span class="lineno"> 70</span> };</div>
  165. <div class="line"><a id="l00071" name="l00071"></a><span class="lineno"> 71</span> </div>
  166. <div class="line"><a id="l00072" name="l00072"></a><span class="lineno"> 72</span> <span class="comment">// Get bounds of both shapes</span></div>
  167. <div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> <a class="code hl_class" href="class_a_a_box.html">AABox</a> bounds1 = inShape1-&gt;<a class="code hl_function" href="class_shape.html#a9f8379fa338802436700b86a07fab3be">GetWorldSpaceBounds</a>(inCenterOfMassTransform1, inScale1);</div>
  168. <div class="line"><a id="l00074" name="l00074"></a><span class="lineno"> 74</span> <a class="code hl_class" href="class_a_a_box.html">AABox</a> bounds2 = inShape2-&gt;<a class="code hl_function" href="class_shape.html#a9f8379fa338802436700b86a07fab3be">GetWorldSpaceBounds</a>(inCenterOfMassTransform2, inScale2);</div>
  169. <div class="line"><a id="l00075" name="l00075"></a><span class="lineno"> 75</span> </div>
  170. <div class="line"><a id="l00076" name="l00076"></a><span class="lineno"> 76</span> <span class="comment">// Get leaf shapes that overlap with the bounds of the other shape</span></div>
  171. <div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> MyCollector leaf_shapes1, leaf_shapes2;</div>
  172. <div class="line"><a id="l00078" name="l00078"></a><span class="lineno"> 78</span> inShape1-&gt;<a class="code hl_function" href="class_shape.html#a3ed865e7eb30221b418cfd61d1430173">CollectTransformedShapes</a>(bounds2, inCenterOfMassTransform1.<a class="code hl_function" href="class_mat44.html#abd89da8ac7b4e4c5b87c02caabbf10b8">GetTranslation</a>(), inCenterOfMassTransform1.<a class="code hl_function" href="class_mat44.html#a1e977c53b5f6a0c03f8da33ebef2c05a">GetQuaternion</a>(), inScale1, inSubShapeIDCreator1, leaf_shapes1, inShapeFilter);</div>
  173. <div class="line"><a id="l00079" name="l00079"></a><span class="lineno"> 79</span> inShape2-&gt;<a class="code hl_function" href="class_shape.html#a3ed865e7eb30221b418cfd61d1430173">CollectTransformedShapes</a>(bounds1, inCenterOfMassTransform2.<a class="code hl_function" href="class_mat44.html#abd89da8ac7b4e4c5b87c02caabbf10b8">GetTranslation</a>(), inCenterOfMassTransform2.<a class="code hl_function" href="class_mat44.html#a1e977c53b5f6a0c03f8da33ebef2c05a">GetQuaternion</a>(), inScale2, inSubShapeIDCreator2, leaf_shapes2, inShapeFilter);</div>
  174. <div class="line"><a id="l00080" name="l00080"></a><span class="lineno"> 80</span> </div>
  175. <div class="line"><a id="l00081" name="l00081"></a><span class="lineno"> 81</span> <span class="comment">// Now test each leaf shape against each other leaf</span></div>
  176. <div class="line"><a id="l00082" name="l00082"></a><span class="lineno"> 82</span> <span class="keywordflow">for</span> (<span class="keyword">const</span> LeafShape &amp;leaf1 : leaf_shapes1.mHits)</div>
  177. <div class="line"><a id="l00083" name="l00083"></a><span class="lineno"> 83</span> <span class="keywordflow">for</span> (<span class="keyword">const</span> LeafShape &amp;leaf2 : leaf_shapes2.mHits)</div>
  178. <div class="line"><a id="l00084" name="l00084"></a><span class="lineno"> 84</span> <span class="keywordflow">if</span> (leaf1.mBounds.Overlaps(leaf2.mBounds))</div>
  179. <div class="line"><a id="l00085" name="l00085"></a><span class="lineno"> 85</span> {</div>
  180. <div class="line"><a id="l00086" name="l00086"></a><span class="lineno"> 86</span> <span class="comment">// Use the leaf collector to collect max 1 hit for this pair and pass it on to ioCollector</span></div>
  181. <div class="line"><a id="l00087" name="l00087"></a><span class="lineno"> 87</span> LeafCollector collector;</div>
  182. <div class="line"><a id="l00088" name="l00088"></a><span class="lineno"> 88</span> <a class="code hl_function" href="class_collision_dispatch.html#a29634d08db5d24ce7c0d5c44b547c075">CollisionDispatch::sCollideShapeVsShape</a>(leaf1.mShape, leaf2.mShape, leaf1.mScale, leaf2.mScale, leaf1.mCenterOfMassTransform, leaf2.mCenterOfMassTransform, leaf1.mSubShapeIDCreator, leaf2.mSubShapeIDCreator, inCollideShapeSettings, collector, inShapeFilter);</div>
  183. <div class="line"><a id="l00089" name="l00089"></a><span class="lineno"> 89</span> <span class="keywordflow">if</span> (collector.HadHit())</div>
  184. <div class="line"><a id="l00090" name="l00090"></a><span class="lineno"> 90</span> ioCollector.<a class="code hl_function" href="class_collision_collector.html#a762c35402676662897e50dd8224e496e">AddHit</a>(collector.mHit);</div>
  185. <div class="line"><a id="l00091" name="l00091"></a><span class="lineno"> 91</span> }</div>
  186. <div class="line"><a id="l00092" name="l00092"></a><span class="lineno"> 92</span>}</div>
  187. </div>
  188. <div class="line"><a id="l00093" name="l00093"></a><span class="lineno"> 93</span> </div>
  189. <div class="line"><a id="l00094" name="l00094"></a><span class="lineno"> 94</span><a class="code hl_define" href="_core_8h.html#a73da8725998b00321a9db341202d650d">JPH_NAMESPACE_END</a></div>
  190. <div class="ttc" id="a_collide_shape_8h_html"><div class="ttname"><a href="_collide_shape_8h.html">CollideShape.h</a></div></div>
  191. <div class="ttc" id="a_collide_shape_vs_shape_per_leaf_8h_html_a78921979ac4a2f3e4d5b6ded9cea4d3d"><div class="ttname"><a href="_collide_shape_vs_shape_per_leaf_8h.html#a78921979ac4a2f3e4d5b6ded9cea4d3d">CollideShapeVsShapePerLeaf</a></div><div class="ttdeci">JPH_NAMESPACE_BEGIN void CollideShapeVsShapePerLeaf(const Shape *inShape1, const Shape *inShape2, Vec3Arg inScale1, Vec3Arg inScale2, Mat44Arg inCenterOfMassTransform1, Mat44Arg inCenterOfMassTransform2, const SubShapeIDCreator &amp;inSubShapeIDCreator1, const SubShapeIDCreator &amp;inSubShapeIDCreator2, const CollideShapeSettings &amp;inCollideShapeSettings, CollideShapeCollector &amp;ioCollector, const ShapeFilter &amp;inShapeFilter={ })</div><div class="ttdef"><b>Definition</b> CollideShapeVsShapePerLeaf.h:30</div></div>
  192. <div class="ttc" id="a_collision_dispatch_8h_html"><div class="ttname"><a href="_collision_dispatch_8h.html">CollisionDispatch.h</a></div></div>
  193. <div class="ttc" id="a_core_8h_html_a69aa29b598b851b0640aa225a9e5d61d"><div class="ttname"><a href="_core_8h.html#a69aa29b598b851b0640aa225a9e5d61d">uint</a></div><div class="ttdeci">unsigned int uint</div><div class="ttdef"><b>Definition</b> Core.h:500</div></div>
  194. <div class="ttc" id="a_core_8h_html_a73da8725998b00321a9db341202d650d"><div class="ttname"><a href="_core_8h.html#a73da8725998b00321a9db341202d650d">JPH_NAMESPACE_END</a></div><div class="ttdeci">#define JPH_NAMESPACE_END</div><div class="ttdef"><b>Definition</b> Core.h:425</div></div>
  195. <div class="ttc" id="a_core_8h_html_ad14098b68b8c44ea6112601031268405"><div class="ttname"><a href="_core_8h.html#ad14098b68b8c44ea6112601031268405">JPH_NAMESPACE_BEGIN</a></div><div class="ttdeci">#define JPH_NAMESPACE_BEGIN</div><div class="ttdef"><b>Definition</b> Core.h:419</div></div>
  196. <div class="ttc" id="a_s_t_l_local_allocator_8h_html"><div class="ttname"><a href="_s_t_l_local_allocator_8h.html">STLLocalAllocator.h</a></div></div>
  197. <div class="ttc" id="a_transformed_shape_8h_html"><div class="ttname"><a href="_transformed_shape_8h.html">TransformedShape.h</a></div></div>
  198. <div class="ttc" id="aclass_a_a_box_html"><div class="ttname"><a href="class_a_a_box.html">AABox</a></div><div class="ttdoc">Axis aligned box.</div><div class="ttdef"><b>Definition</b> AABox.h:16</div></div>
  199. <div class="ttc" id="aclass_array_html"><div class="ttname"><a href="class_array.html">Array</a></div><div class="ttdef"><b>Definition</b> Array.h:36</div></div>
  200. <div class="ttc" id="aclass_collide_shape_settings_html"><div class="ttname"><a href="class_collide_shape_settings.html">CollideShapeSettings</a></div><div class="ttdoc">Settings to be passed with a collision query.</div><div class="ttdef"><b>Definition</b> CollideShape.h:94</div></div>
  201. <div class="ttc" id="aclass_collision_collector_html"><div class="ttname"><a href="class_collision_collector.html">CollisionCollector</a></div><div class="ttdoc">Virtual interface that allows collecting multiple collision results.</div><div class="ttdef"><b>Definition</b> CollisionCollector.h:45</div></div>
  202. <div class="ttc" id="aclass_collision_collector_html_a762c35402676662897e50dd8224e496e"><div class="ttname"><a href="class_collision_collector.html#a762c35402676662897e50dd8224e496e">CollisionCollector::AddHit</a></div><div class="ttdeci">virtual void AddHit(const ResultType &amp;inResult)=0</div><div class="ttdoc">This function will be called for every hit found, it's up to the application to decide how to store t...</div></div>
  203. <div class="ttc" id="aclass_collision_dispatch_html_a29634d08db5d24ce7c0d5c44b547c075"><div class="ttname"><a href="class_collision_dispatch.html#a29634d08db5d24ce7c0d5c44b547c075">CollisionDispatch::sCollideShapeVsShape</a></div><div class="ttdeci">static void sCollideShapeVsShape(const Shape *inShape1, const Shape *inShape2, Vec3Arg inScale1, Vec3Arg inScale2, Mat44Arg inCenterOfMassTransform1, Mat44Arg inCenterOfMassTransform2, const SubShapeIDCreator &amp;inSubShapeIDCreator1, const SubShapeIDCreator &amp;inSubShapeIDCreator2, const CollideShapeSettings &amp;inCollideShapeSettings, CollideShapeCollector &amp;ioCollector, const ShapeFilter &amp;inShapeFilter={ })</div><div class="ttdef"><b>Definition</b> CollisionDispatch.h:33</div></div>
  204. <div class="ttc" id="aclass_mat44_html"><div class="ttname"><a href="class_mat44.html">Mat44</a></div><div class="ttdoc">Holds a 4x4 matrix of floats, but supports also operations on the 3x3 upper left part of the matrix.</div><div class="ttdef"><b>Definition</b> Mat44.h:13</div></div>
  205. <div class="ttc" id="aclass_mat44_html_a1e977c53b5f6a0c03f8da33ebef2c05a"><div class="ttname"><a href="class_mat44.html#a1e977c53b5f6a0c03f8da33ebef2c05a">Mat44::GetQuaternion</a></div><div class="ttdeci">JPH_INLINE Quat GetQuaternion() const</div><div class="ttdoc">Convert to quaternion.</div><div class="ttdef"><b>Definition</b> Mat44.inl:783</div></div>
  206. <div class="ttc" id="aclass_mat44_html_a3445a728646fe8ad80381a0e55ea2289"><div class="ttname"><a href="class_mat44.html#a3445a728646fe8ad80381a0e55ea2289">Mat44::ToMat44</a></div><div class="ttdeci">JPH_INLINE Mat44 ToMat44() const</div><div class="ttdoc">In single precision mode just return the matrix itself.</div><div class="ttdef"><b>Definition</b> Mat44.h:225</div></div>
  207. <div class="ttc" id="aclass_mat44_html_abd89da8ac7b4e4c5b87c02caabbf10b8"><div class="ttname"><a href="class_mat44.html#abd89da8ac7b4e4c5b87c02caabbf10b8">Mat44::GetTranslation</a></div><div class="ttdeci">JPH_INLINE Vec3 GetTranslation() const</div><div class="ttdef"><b>Definition</b> Mat44.h:152</div></div>
  208. <div class="ttc" id="aclass_shape_filter_html"><div class="ttname"><a href="class_shape_filter.html">ShapeFilter</a></div><div class="ttdoc">Filter class.</div><div class="ttdef"><b>Definition</b> ShapeFilter.h:17</div></div>
  209. <div class="ttc" id="aclass_shape_html"><div class="ttname"><a href="class_shape.html">Shape</a></div><div class="ttdoc">Base class for all shapes (collision volume of a body). Defines a virtual interface for collision det...</div><div class="ttdef"><b>Definition</b> Shape.h:186</div></div>
  210. <div class="ttc" id="aclass_shape_html_a3ed865e7eb30221b418cfd61d1430173"><div class="ttname"><a href="class_shape.html#a3ed865e7eb30221b418cfd61d1430173">Shape::CollectTransformedShapes</a></div><div class="ttdeci">virtual void CollectTransformedShapes(const AABox &amp;inBox, Vec3Arg inPositionCOM, QuatArg inRotation, Vec3Arg inScale, const SubShapeIDCreator &amp;inSubShapeIDCreator, TransformedShapeCollector &amp;ioCollector, const ShapeFilter &amp;inShapeFilter) const</div><div class="ttdef"><b>Definition</b> Shape.cpp:52</div></div>
  211. <div class="ttc" id="aclass_shape_html_a9f8379fa338802436700b86a07fab3be"><div class="ttname"><a href="class_shape.html#a9f8379fa338802436700b86a07fab3be">Shape::GetWorldSpaceBounds</a></div><div class="ttdeci">virtual AABox GetWorldSpaceBounds(Mat44Arg inCenterOfMassTransform, Vec3Arg inScale) const</div><div class="ttdef"><b>Definition</b> Shape.h:222</div></div>
  212. <div class="ttc" id="aclass_sub_shape_i_d_creator_html"><div class="ttname"><a href="class_sub_shape_i_d_creator.html">SubShapeIDCreator</a></div><div class="ttdef"><b>Definition</b> SubShapeID.h:108</div></div>
  213. <div class="ttc" id="aclass_transformed_shape_html"><div class="ttname"><a href="class_transformed_shape.html">TransformedShape</a></div><div class="ttdef"><b>Definition</b> TransformedShape.h:26</div></div>
  214. <div class="ttc" id="aclass_transformed_shape_html_a33b12d09ebaf2071dd49a3873978ac0a"><div class="ttname"><a href="class_transformed_shape.html#a33b12d09ebaf2071dd49a3873978ac0a">TransformedShape::GetWorldSpaceBounds</a></div><div class="ttdeci">AABox GetWorldSpaceBounds() const</div><div class="ttdoc">Get the world space bounding box for this transformed shape.</div><div class="ttdef"><b>Definition</b> TransformedShape.h:123</div></div>
  215. <div class="ttc" id="aclass_transformed_shape_html_a3d0b38db0aacff1c3188a0c20f45e713"><div class="ttname"><a href="class_transformed_shape.html#a3d0b38db0aacff1c3188a0c20f45e713">TransformedShape::mSubShapeIDCreator</a></div><div class="ttdeci">SubShapeIDCreator mSubShapeIDCreator</div><div class="ttdoc">Optional sub shape ID creator for the shape (can be used when expanding compound shapes into multiple...</div><div class="ttdef"><b>Definition</b> TransformedShape.h:188</div></div>
  216. <div class="ttc" id="aclass_transformed_shape_html_a9f0559c4106b9b17becd5f401389b354"><div class="ttname"><a href="class_transformed_shape.html#a9f0559c4106b9b17becd5f401389b354">TransformedShape::GetShapeScale</a></div><div class="ttdeci">Vec3 GetShapeScale() const</div><div class="ttdoc">Get/set the scale of the shape as a Vec3.</div><div class="ttdef"><b>Definition</b> TransformedShape.h:89</div></div>
  217. <div class="ttc" id="aclass_transformed_shape_html_ac6aaf976fee41c402c791012e4a2a3f9"><div class="ttname"><a href="class_transformed_shape.html#ac6aaf976fee41c402c791012e4a2a3f9">TransformedShape::mShape</a></div><div class="ttdeci">RefConst&lt; Shape &gt; mShape</div><div class="ttdoc">The shape itself.</div><div class="ttdef"><b>Definition</b> TransformedShape.h:185</div></div>
  218. <div class="ttc" id="aclass_transformed_shape_html_afba760db30ccff8c59547cce78bd97a4"><div class="ttname"><a href="class_transformed_shape.html#afba760db30ccff8c59547cce78bd97a4">TransformedShape::GetCenterOfMassTransform</a></div><div class="ttdeci">RMat44 GetCenterOfMassTransform() const</div><div class="ttdoc">Calculates the transform for this shape's center of mass (excluding scale)</div><div class="ttdef"><b>Definition</b> TransformedShape.h:93</div></div>
  219. <div class="ttc" id="aclass_vec3_html"><div class="ttname"><a href="class_vec3.html">Vec3</a></div><div class="ttdef"><b>Definition</b> Vec3.h:17</div></div>
  220. </div><!-- fragment --></div><!-- contents -->
  221. </div><!-- doc-content -->
  222. <!-- start footer part -->
  223. <div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  224. <ul>
  225. <li class="navelem"><a class="el" href="dir_d99289a5d3c46cf26f14ff6c90658d9f.html">Jolt</a></li><li class="navelem"><a class="el" href="dir_a0f33af92addde396fc27b064c5eb8a9.html">Physics</a></li><li class="navelem"><a class="el" href="dir_1a1d05ab9ff27ca8d1ed94cd62670cdf.html">Collision</a></li><li class="navelem"><a class="el" href="_collide_shape_vs_shape_per_leaf_8h.html">CollideShapeVsShapePerLeaf.h</a></li>
  226. <li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.12.0 </li>
  227. </ul>
  228. </div>
  229. </body>
  230. </html>