From 9f4fc41dc5d857e3c7c3500fc71953e54d780a39 Mon Sep 17 00:00:00 2001 From: Bryan Galdrikian Date: Tue, 17 Sep 2019 09:16:55 -0700 Subject: * NvBlastAsset::testForValidChunkOrder (used when creating an NvBlastAsset) is now more strict, requiring parent chunk descriptors to come before their children. It is still less strict than the order created by NvBlastBuildAssetDescChunkReorderMap. * Added FractureTool::setApproximateBonding function. Signals the tool to create bonds by proximity instead of just using cut plane data. * Chunks which have been merged using the uniteChunks function may be merged again * Restored chunk volume calculation * NvBlastBuildAssetDescChunkReorderMap failure cases fixed. --- docs/source_docs/files/_nv_blast_8h.html | 2 +- .../files/_nv_blast_actor_8h_source.html | 6 +- .../files/_nv_blast_asset_8h-source.html | 156 +++---- .../files/_nv_blast_asset_8h_source.html | 28 +- ...blast_ext_authoring_boolean_tool_8h_source.html | 2 +- ...last_ext_authoring_fracture_tool_8h-source.html | 24 +- ...last_ext_authoring_fracture_tool_8h_source.html | 4 +- ...ext_authoring_fracture_tool_impl_8h-source.html | 84 ++-- ...ext_authoring_fracture_tool_impl_8h_source.html | 18 +- ...st_ext_authoring_internal_common_8h-source.html | 468 +++++++++++---------- ..._nv_blast_ext_authoring_internal_common_8h.html | 3 + .../_nv_blast_ext_authoring_internal_common_8h.js | 1 + ...st_ext_authoring_internal_common_8h_source.html | 65 +-- ...blast_ext_authoring_triangulator_8h_source.html | 4 +- .../_nv_blast_ext_r_t_geometry_8h_source.html | 2 +- .../files/_nv_blast_family_8h_source.html | 12 +- .../files/class_nv_1_1_blast_1_1_asset.html | 2 +- ...ass_nv_1_1_blast_1_1_fracture_tool-members.html | 1 + .../class_nv_1_1_blast_1_1_fracture_tool.html | 40 ++ .../files/class_nv_1_1_blast_1_1_fracture_tool.js | 1 + ...v_1_1_blast_1_1_fracture_tool_impl-members.html | 1 + .../class_nv_1_1_blast_1_1_fracture_tool_impl.html | 40 ++ .../class_nv_1_1_blast_1_1_fracture_tool_impl.js | 1 + docs/source_docs/files/functions_0x61.html | 50 +-- docs/source_docs/files/functions_0x63.html | 61 ++- docs/source_docs/files/functions_0x69.html | 4 +- docs/source_docs/files/functions_0x70.html | 13 +- docs/source_docs/files/functions_0x72.html | 4 +- docs/source_docs/files/functions_0x73.html | 70 +-- docs/source_docs/files/functions_0x74.html | 22 +- docs/source_docs/files/functions_0x75.html | 19 +- docs/source_docs/files/functions_0x79.html | 19 +- docs/source_docs/files/functions_a.html | 7 +- docs/source_docs/files/functions_c.html | 11 +- docs/source_docs/files/functions_eval.html | 14 +- docs/source_docs/files/functions_func_0x69.html | 4 +- docs/source_docs/files/functions_func_0x70.html | 3 +- docs/source_docs/files/functions_func_0x72.html | 4 +- docs/source_docs/files/functions_func_0x73.html | 64 +-- docs/source_docs/files/functions_func_g.html | 2 +- docs/source_docs/files/functions_func_s.html | 14 +- docs/source_docs/files/functions_g.html | 2 +- docs/source_docs/files/functions_s.html | 22 +- docs/source_docs/files/functions_type.html | 8 +- docs/source_docs/files/functions_vars_0x75.html | 21 +- docs/source_docs/files/functions_y.html | 4 +- docs/source_docs/files/namespace_nv_1_1_blast.html | 22 + docs/source_docs/files/namespacemembers_0x63.html | 4 +- docs/source_docs/files/namespacemembers_c.html | 5 +- .../files/namespacemembers_func_0x63.html | 4 +- .../source_docs/files/namespacemembers_func_c.html | 5 +- docs/source_docs/files/navtreedata.js | 38 +- docs/source_docs/files/navtreeindex1.js | 18 +- docs/source_docs/files/navtreeindex10.js | 8 +- docs/source_docs/files/navtreeindex11.js | 8 +- docs/source_docs/files/navtreeindex12.js | 8 +- docs/source_docs/files/navtreeindex13.js | 8 +- docs/source_docs/files/navtreeindex14.js | 8 +- docs/source_docs/files/navtreeindex15.js | 58 +-- docs/source_docs/files/navtreeindex16.js | 12 +- docs/source_docs/files/navtreeindex17.js | 8 +- docs/source_docs/files/navtreeindex18.js | 8 +- docs/source_docs/files/navtreeindex19.js | 8 +- docs/source_docs/files/navtreeindex2.js | 4 +- docs/source_docs/files/navtreeindex20.js | 3 + docs/source_docs/files/navtreeindex3.js | 4 +- docs/source_docs/files/navtreeindex4.js | 4 +- docs/source_docs/files/navtreeindex5.js | 4 +- docs/source_docs/files/navtreeindex6.js | 4 +- docs/source_docs/files/navtreeindex7.js | 60 +-- docs/source_docs/files/navtreeindex8.js | 8 +- docs/source_docs/files/navtreeindex9.js | 8 +- ...struct_nv_1_1_blast_1_1_chunk_info-members.html | 2 +- .../files/struct_nv_1_1_blast_1_1_chunk_info.html | 6 +- .../files/struct_nv_1_1_blast_1_1_chunk_info.js | 2 +- 75 files changed, 968 insertions(+), 778 deletions(-) (limited to 'docs/source_docs') diff --git a/docs/source_docs/files/_nv_blast_8h.html b/docs/source_docs/files/_nv_blast_8h.html index b70d432..ae5675b 100755 --- a/docs/source_docs/files/_nv_blast_8h.html +++ b/docs/source_docs/files/_nv_blast_8h.html @@ -1768,7 +1768,7 @@ Iff chunks are already ordered correctly, function returns 'true' and identity c [out] chunkReorderMap User-supplied map of size chunkCount to fill. For every chunk index this array will contain new chunk position (index). [in] chunkDescs Array of chunk descriptors of size chunkCount. [in] chunkCount The number of chunk descriptors. - [in] scratch User-supplied scratch storage, must point to 2 * chunkCount * sizeof(uint32_t) valid bytes of memory. + [in] scratch User-supplied scratch storage, must point to 3 * chunkCount * sizeof(uint32_t) valid bytes of memory. [in] logFn User-supplied message function (see NvBlastLog definition). May be NULL. diff --git a/docs/source_docs/files/_nv_blast_actor_8h_source.html b/docs/source_docs/files/_nv_blast_actor_8h_source.html index b600574..339d3a7 100755 --- a/docs/source_docs/files/_nv_blast_actor_8h_source.html +++ b/docs/source_docs/files/_nv_blast_actor_8h_source.html @@ -92,13 +92,13 @@ $(document).ready(function(){initNavTree('_nv_blast_actor_8h_source.html','');})
bool isBoundToWorld() const
Definition: NvBlastActor.h:675
Definition: NvBlastTypes.h:481
uint32_t childIndexStop
Definition: NvBlastTypes.h:177
-
uint32_t m_firstSubsupportChunkIndex
Definition: NvBlastAsset.h:206
+
uint32_t m_firstSubsupportChunkIndex
Definition: NvBlastAsset.h:207
const Asset * m_asset
Definition: NvBlastFamily.h:148
uint32_t bondFractureCount
available elements in bondFractures
Definition: NvBlastTypes.h:470
const SupportGraph * getGraph() const
Definition: NvBlastActor.h:575
float * getSubsupportChunkHealths() const
Definition: NvBlastActor.h:600
-
Definition: NvBlastAsset.h:252
+
Definition: NvBlastAsset.h:253
uint32_t findIslands(void *scratch)
Definition: NvBlastActor.h:233
uint32_t serializationRequiredStorage(NvBlastLog logFn) const
@@ -113,7 +113,7 @@ $(document).ready(function(){initNavTree('_nv_blast_actor_8h_source.html','');})
float * getSubsupportChunkHealths() const
Definition: NvBlastFamily.h:113
-
SupportGraph m_graph
Definition: NvBlastAsset.h:196
+
SupportGraph m_graph
Definition: NvBlastAsset.h:197
Definition: NvBlastIteratorBase.h:88
Definition: NvBlastTypes.h:468
Definition: NvBlastActor.h:58
diff --git a/docs/source_docs/files/_nv_blast_asset_8h-source.html b/docs/source_docs/files/_nv_blast_asset_8h-source.html index 607e77a..e597ad4 100755 --- a/docs/source_docs/files/_nv_blast_asset_8h-source.html +++ b/docs/source_docs/files/_nv_blast_asset_8h-source.html @@ -120,93 +120,93 @@ 00136 00156 static bool ensureExactSupportCoverage(uint32_t& supportChunkCount, uint32_t& leafChunkCount, char* chunkAnnotation, uint32_t chunkCount, NvBlastChunkDesc* chunkDescs, bool testOnly, NvBlastLog logFn); 00157 -00173 static bool testForValidChunkOrder(uint32_t chunkCount, const NvBlastChunkDesc* chunkDescs, const char* chunkAnnotation, void* scratch); -00174 +00174 static bool testForValidChunkOrder(uint32_t chunkCount, const NvBlastChunkDesc* chunkDescs, const char* chunkAnnotation, void* scratch); 00175 -00177 -00181 NvBlastDataBlock m_header; -00182 -00186 NvBlastID m_ID; -00187 -00191 uint32_t m_chunkCount; -00192 -00196 SupportGraph m_graph; -00197 -00201 uint32_t m_leafChunkCount; -00202 -00206 uint32_t m_firstSubsupportChunkIndex; -00207 -00211 uint32_t m_bondCount; -00212 -00218 NvBlastBlockArrayData(NvBlastChunk, m_chunksOffset, getChunks, m_chunkCount); -00219 -00228 NvBlastBlockArrayData(NvBlastBond, m_bondsOffset, getBonds, m_bondCount); -00229 -00236 NvBlastBlockArrayData(uint32_t, m_subtreeLeafChunkCountsOffset, getSubtreeLeafChunkCounts, m_chunkCount); -00237 -00243 NvBlastBlockArrayData(uint32_t, m_chunkToGraphNodeMapOffset, getChunkToGraphNodeMap, m_chunkCount); -00244 +00176 +00178 +00182 NvBlastDataBlock m_header; +00183 +00187 NvBlastID m_ID; +00188 +00192 uint32_t m_chunkCount; +00193 +00197 SupportGraph m_graph; +00198 +00202 uint32_t m_leafChunkCount; +00203 +00207 uint32_t m_firstSubsupportChunkIndex; +00208 +00212 uint32_t m_bondCount; +00213 +00219 NvBlastBlockArrayData(NvBlastChunk, m_chunksOffset, getChunks, m_chunkCount); +00220 +00229 NvBlastBlockArrayData(NvBlastBond, m_bondsOffset, getBonds, m_bondCount); +00230 +00237 NvBlastBlockArrayData(uint32_t, m_subtreeLeafChunkCountsOffset, getSubtreeLeafChunkCounts, m_chunkCount); +00238 +00244 NvBlastBlockArrayData(uint32_t, m_chunkToGraphNodeMapOffset, getChunkToGraphNodeMap, m_chunkCount); 00245 -00247 -00252 class DepthFirstIt : public ChunkDepthFirstIt -00253 { -00254 public: -00256 DepthFirstIt(const Asset& asset, uint32_t startChunkIndex, bool upperSupportOnly = false) : -00257 ChunkDepthFirstIt(asset.getChunks(), startChunkIndex, upperSupportOnly ? asset.getUpperSupportChunkCount() : asset.m_chunkCount) {} -00258 }; -00259 }; -00260 +00246 +00248 +00253 class DepthFirstIt : public ChunkDepthFirstIt +00254 { +00255 public: +00257 DepthFirstIt(const Asset& asset, uint32_t startChunkIndex, bool upperSupportOnly = false) : +00258 ChunkDepthFirstIt(asset.getChunks(), startChunkIndex, upperSupportOnly ? asset.getUpperSupportChunkCount() : asset.m_chunkCount) {} +00259 }; +00260 }; 00261 -00263 -00264 NV_INLINE uint32_t Asset::getUpperSupportChunkCount() const -00265 { -00266 return m_firstSubsupportChunkIndex; -00267 } -00268 +00262 +00264 +00265 NV_INLINE uint32_t Asset::getUpperSupportChunkCount() const +00266 { +00267 return m_firstSubsupportChunkIndex; +00268 } 00269 -00270 NV_INLINE uint32_t Asset::getLowerSupportChunkCount() const -00271 { -00272 return m_graph.m_nodeCount + (m_chunkCount - m_firstSubsupportChunkIndex); -00273 } -00274 +00270 +00271 NV_INLINE uint32_t Asset::getLowerSupportChunkCount() const +00272 { +00273 return m_graph.m_nodeCount + (m_chunkCount - m_firstSubsupportChunkIndex); +00274 } 00275 -00276 NV_INLINE uint32_t Asset::getBondCount() const -00277 { -00278 NVBLAST_ASSERT((m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] & 1) == 0); // The bidirectional graph data should have an even number of edges -00279 return m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] / 2; // Directional bonds, divide by two -00280 } -00281 +00276 +00277 NV_INLINE uint32_t Asset::getBondCount() const +00278 { +00279 NVBLAST_ASSERT((m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] & 1) == 0); // The bidirectional graph data should have an even number of edges +00280 return m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] / 2; // Directional bonds, divide by two +00281 } 00282 -00283 NV_INLINE uint32_t Asset::getHierarchyCount() const -00284 { -00285 const NvBlastChunk* chunks = getChunks(); -00286 for (uint32_t i = 0; i < m_chunkCount; ++i) -00287 { -00288 if (!isInvalidIndex(chunks[i].parentChunkIndex)) -00289 { -00290 return i; -00291 } -00292 } -00293 return m_chunkCount; -00294 } -00295 +00283 +00284 NV_INLINE uint32_t Asset::getHierarchyCount() const +00285 { +00286 const NvBlastChunk* chunks = getChunks(); +00287 for (uint32_t i = 0; i < m_chunkCount; ++i) +00288 { +00289 if (!isInvalidIndex(chunks[i].parentChunkIndex)) +00290 { +00291 return i; +00292 } +00293 } +00294 return m_chunkCount; +00295 } 00296 -00297 NV_INLINE uint32_t Asset::getContiguousLowerSupportIndex(uint32_t chunkIndex) const -00298 { -00299 NVBLAST_ASSERT(chunkIndex < m_chunkCount); -00300 -00301 return chunkIndex < m_firstSubsupportChunkIndex ? getChunkToGraphNodeMap()[chunkIndex] : (chunkIndex - m_firstSubsupportChunkIndex + m_graph.m_nodeCount); -00302 } -00303 +00297 +00298 NV_INLINE uint32_t Asset::getContiguousLowerSupportIndex(uint32_t chunkIndex) const +00299 { +00300 NVBLAST_ASSERT(chunkIndex < m_chunkCount); +00301 +00302 return chunkIndex < m_firstSubsupportChunkIndex ? getChunkToGraphNodeMap()[chunkIndex] : (chunkIndex - m_firstSubsupportChunkIndex + m_graph.m_nodeCount); +00303 } 00304 -00305 //JDM: Expose this so serialization layer can use it. -00306 NVBLAST_API Asset* initializeAsset(void* mem, NvBlastID id, uint32_t chunkCount, uint32_t graphNodeCount, uint32_t leafChunkCount, uint32_t firstSubsupportChunkIndex, uint32_t bondCount, NvBlastLog logFn); -00307 -00308 } // namespace Blast -00309 } // namespace Nv -00310 +00305 +00306 //JDM: Expose this so serialization layer can use it. +00307 NVBLAST_API Asset* initializeAsset(void* mem, NvBlastID id, uint32_t chunkCount, uint32_t graphNodeCount, uint32_t leafChunkCount, uint32_t firstSubsupportChunkIndex, uint32_t bondCount, NvBlastLog logFn); +00308 +00309 } // namespace Blast +00310 } // namespace Nv 00311 -00312 #endif // ifndef NVBLASTASSET_H +00312 +00313 #endif // ifndef NVBLASTASSET_H
-Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTASSET_H
30 #define NVBLASTASSET_H
31 
32 
33 #include "NvBlastSupportGraph.h"
34 #include "NvBlast.h"
35 #include "NvBlastAssert.h"
36 #include "NvBlastIndexFns.h"
37 #include "NvBlastChunkHierarchy.h"
38 
39 
40 namespace Nv
41 {
42 namespace Blast
43 {
44 
45 class Asset : public NvBlastAsset
46 {
47 public:
48 
53  {
54  enum Enum
55  {
56  Parent = (1 << 0),
57  Support = (1 << 1),
58  SuperSupport = (1 << 2),
59 
60  // Combinations
62  };
63  };
64 
65 
76  static Asset* create(void* mem, const NvBlastAssetDesc* desc, void* scratch, NvBlastLog logFn);
77 
84  static size_t getMemorySize(const NvBlastAssetDesc* desc);
85 
94  static size_t createRequiredScratch(const NvBlastAssetDesc* desc);
95 
96 
102  uint32_t getUpperSupportChunkCount() const;
103 
109  uint32_t getLowerSupportChunkCount() const;
110 
116  uint32_t getBondCount() const;
117 
123  uint32_t getHierarchyCount() const;
124 
132  uint32_t getContiguousLowerSupportIndex(uint32_t chunkIndex) const;
133 
134 
135  // Static functions
136 
156  static bool ensureExactSupportCoverage(uint32_t& supportChunkCount, uint32_t& leafChunkCount, char* chunkAnnotation, uint32_t chunkCount, NvBlastChunkDesc* chunkDescs, bool testOnly, NvBlastLog logFn);
157 
173  static bool testForValidChunkOrder(uint32_t chunkCount, const NvBlastChunkDesc* chunkDescs, const char* chunkAnnotation, void* scratch);
174 
175 
177 
182 
187 
191  uint32_t m_chunkCount;
192 
197 
202 
207 
211  uint32_t m_bondCount;
212 
218  NvBlastBlockArrayData(NvBlastChunk, m_chunksOffset, getChunks, m_chunkCount);
219 
228  NvBlastBlockArrayData(NvBlastBond, m_bondsOffset, getBonds, m_bondCount);
229 
236  NvBlastBlockArrayData(uint32_t, m_subtreeLeafChunkCountsOffset, getSubtreeLeafChunkCounts, m_chunkCount);
237 
243  NvBlastBlockArrayData(uint32_t, m_chunkToGraphNodeMapOffset, getChunkToGraphNodeMap, m_chunkCount);
244 
245 
247 
253  {
254  public:
256  DepthFirstIt(const Asset& asset, uint32_t startChunkIndex, bool upperSupportOnly = false) :
257  ChunkDepthFirstIt(asset.getChunks(), startChunkIndex, upperSupportOnly ? asset.getUpperSupportChunkCount() : asset.m_chunkCount) {}
258  };
259 };
260 
261 
263 
265 {
267 }
268 
269 
271 {
273 }
274 
275 
277 {
278  NVBLAST_ASSERT((m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] & 1) == 0); // The bidirectional graph data should have an even number of edges
279  return m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] / 2; // Directional bonds, divide by two
280 }
281 
282 
284 {
285  const NvBlastChunk* chunks = getChunks();
286  for (uint32_t i = 0; i < m_chunkCount; ++i)
287  {
288  if (!isInvalidIndex(chunks[i].parentChunkIndex))
289  {
290  return i;
291  }
292  }
293  return m_chunkCount;
294 }
295 
296 
297 NV_INLINE uint32_t Asset::getContiguousLowerSupportIndex(uint32_t chunkIndex) const
298 {
299  NVBLAST_ASSERT(chunkIndex < m_chunkCount);
300 
301  return chunkIndex < m_firstSubsupportChunkIndex ? getChunkToGraphNodeMap()[chunkIndex] : (chunkIndex - m_firstSubsupportChunkIndex + m_graph.m_nodeCount);
302 }
303 
304 
305 //JDM: Expose this so serialization layer can use it.
306 NVBLAST_API Asset* initializeAsset(void* mem, NvBlastID id, uint32_t chunkCount, uint32_t graphNodeCount, uint32_t leafChunkCount, uint32_t firstSubsupportChunkIndex, uint32_t bondCount, NvBlastLog logFn);
307 
308 } // namespace Blast
309 } // namespace Nv
310 
311 
312 #endif // ifndef NVBLASTASSET_H
uint32_t m_bondCount
Definition: NvBlastAsset.h:211
+Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTASSET_H
30 #define NVBLASTASSET_H
31 
32 
33 #include "NvBlastSupportGraph.h"
34 #include "NvBlast.h"
35 #include "NvBlastAssert.h"
36 #include "NvBlastIndexFns.h"
37 #include "NvBlastChunkHierarchy.h"
38 
39 
40 namespace Nv
41 {
42 namespace Blast
43 {
44 
45 class Asset : public NvBlastAsset
46 {
47 public:
48 
53  {
54  enum Enum
55  {
56  Parent = (1 << 0),
57  Support = (1 << 1),
58  SuperSupport = (1 << 2),
59 
60  // Combinations
62  };
63  };
64 
65 
76  static Asset* create(void* mem, const NvBlastAssetDesc* desc, void* scratch, NvBlastLog logFn);
77 
84  static size_t getMemorySize(const NvBlastAssetDesc* desc);
85 
94  static size_t createRequiredScratch(const NvBlastAssetDesc* desc);
95 
96 
102  uint32_t getUpperSupportChunkCount() const;
103 
109  uint32_t getLowerSupportChunkCount() const;
110 
116  uint32_t getBondCount() const;
117 
123  uint32_t getHierarchyCount() const;
124 
132  uint32_t getContiguousLowerSupportIndex(uint32_t chunkIndex) const;
133 
134 
135  // Static functions
136 
156  static bool ensureExactSupportCoverage(uint32_t& supportChunkCount, uint32_t& leafChunkCount, char* chunkAnnotation, uint32_t chunkCount, NvBlastChunkDesc* chunkDescs, bool testOnly, NvBlastLog logFn);
157 
174  static bool testForValidChunkOrder(uint32_t chunkCount, const NvBlastChunkDesc* chunkDescs, const char* chunkAnnotation, void* scratch);
175 
176 
178 
183 
188 
192  uint32_t m_chunkCount;
193 
198 
203 
208 
212  uint32_t m_bondCount;
213 
219  NvBlastBlockArrayData(NvBlastChunk, m_chunksOffset, getChunks, m_chunkCount);
220 
229  NvBlastBlockArrayData(NvBlastBond, m_bondsOffset, getBonds, m_bondCount);
230 
237  NvBlastBlockArrayData(uint32_t, m_subtreeLeafChunkCountsOffset, getSubtreeLeafChunkCounts, m_chunkCount);
238 
244  NvBlastBlockArrayData(uint32_t, m_chunkToGraphNodeMapOffset, getChunkToGraphNodeMap, m_chunkCount);
245 
246 
248 
254  {
255  public:
257  DepthFirstIt(const Asset& asset, uint32_t startChunkIndex, bool upperSupportOnly = false) :
258  ChunkDepthFirstIt(asset.getChunks(), startChunkIndex, upperSupportOnly ? asset.getUpperSupportChunkCount() : asset.m_chunkCount) {}
259  };
260 };
261 
262 
264 
266 {
268 }
269 
270 
272 {
274 }
275 
276 
278 {
279  NVBLAST_ASSERT((m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] & 1) == 0); // The bidirectional graph data should have an even number of edges
280  return m_graph.getAdjacencyPartition()[m_graph.m_nodeCount] / 2; // Directional bonds, divide by two
281 }
282 
283 
285 {
286  const NvBlastChunk* chunks = getChunks();
287  for (uint32_t i = 0; i < m_chunkCount; ++i)
288  {
289  if (!isInvalidIndex(chunks[i].parentChunkIndex))
290  {
291  return i;
292  }
293  }
294  return m_chunkCount;
295 }
296 
297 
298 NV_INLINE uint32_t Asset::getContiguousLowerSupportIndex(uint32_t chunkIndex) const
299 {
300  NVBLAST_ASSERT(chunkIndex < m_chunkCount);
301 
302  return chunkIndex < m_firstSubsupportChunkIndex ? getChunkToGraphNodeMap()[chunkIndex] : (chunkIndex - m_firstSubsupportChunkIndex + m_graph.m_nodeCount);
303 }
304 
305 
306 //JDM: Expose this so serialization layer can use it.
307 NVBLAST_API Asset* initializeAsset(void* mem, NvBlastID id, uint32_t chunkCount, uint32_t graphNodeCount, uint32_t leafChunkCount, uint32_t firstSubsupportChunkIndex, uint32_t bondCount, NvBlastLog logFn);
308 
309 } // namespace Blast
310 } // namespace Nv
311 
312 
313 #endif // ifndef NVBLASTASSET_H
uint32_t m_bondCount
Definition: NvBlastAsset.h:212
static size_t getMemorySize(const NvBlastAssetDesc *desc)
Definition: NvBlastSupportGraph.h:76
@@ -54,12 +54,12 @@ $(document).ready(function(){initNavTree('_nv_blast_asset_8h_source.html','');})
Enum
Definition: NvBlastAsset.h:54
Definition: NvBlastChunkHierarchy.h:49
Definition: NvBlastAsset.h:52
-
uint32_t getBondCount() const
Definition: NvBlastAsset.h:276
+
uint32_t getBondCount() const
Definition: NvBlastAsset.h:277
Definition: NvBlastTypes.h:345
static bool testForValidChunkOrder(uint32_t chunkCount, const NvBlastChunkDesc *chunkDescs, const char *chunkAnnotation, void *scratch)
NV_INLINE bool isInvalidIndex(T index)
Definition: NvBlastIndexFns.h:57
-
uint32_t m_leafChunkCount
Definition: NvBlastAsset.h:201
+
uint32_t m_leafChunkCount
Definition: NvBlastAsset.h:202
Definition: NvBlastAsset.h:56
void(* NvBlastLog)(int type, const char *msg, const char *file, int line)
Definition: NvBlastTypes.h:63
#define NVBLAST_ASSERT(exp)
Definition: NvBlastAssert.h:37
@@ -69,28 +69,28 @@ $(document).ready(function(){initNavTree('_nv_blast_asset_8h_source.html','');})
Definition: NvBlastTypes.h:98
#define NVBLAST_API
Definition: NvBlastPreprocessor.h:37
-
uint32_t m_firstSubsupportChunkIndex
Definition: NvBlastAsset.h:206
-
DepthFirstIt(const Asset &asset, uint32_t startChunkIndex, bool upperSupportOnly=false)
Definition: NvBlastAsset.h:256
-
Definition: NvBlastAsset.h:252
+
uint32_t m_firstSubsupportChunkIndex
Definition: NvBlastAsset.h:207
+
DepthFirstIt(const Asset &asset, uint32_t startChunkIndex, bool upperSupportOnly=false)
Definition: NvBlastAsset.h:257
+
Definition: NvBlastAsset.h:253
NVBLAST_API Asset * initializeAsset(void *mem, NvBlastID id, uint32_t chunkCount, uint32_t graphNodeCount, uint32_t leafChunkCount, uint32_t firstSubsupportChunkIndex, uint32_t bondCount, NvBlastLog logFn)
#define NV_INLINE
Definition: NvPreprocessor.h:350
uint32_t m_nodeCount
Definition: NvBlastSupportGraph.h:81
Definition: NvBlastTypes.h:69
-
uint32_t getContiguousLowerSupportIndex(uint32_t chunkIndex) const
Definition: NvBlastAsset.h:297
-
uint32_t getLowerSupportChunkCount() const
Definition: NvBlastAsset.h:270
-
NvBlastDataBlock m_header
Definition: NvBlastAsset.h:181
+
uint32_t getContiguousLowerSupportIndex(uint32_t chunkIndex) const
Definition: NvBlastAsset.h:298
+
uint32_t getLowerSupportChunkCount() const
Definition: NvBlastAsset.h:271
+
NvBlastDataBlock m_header
Definition: NvBlastAsset.h:182
Definition: NvBlastTypes.h:292
Definition: NvBlastTypes.h:152
-
SupportGraph m_graph
Definition: NvBlastAsset.h:196
+
SupportGraph m_graph
Definition: NvBlastAsset.h:197
Definition: NvBlastTypes.h:286
static Asset * create(void *mem, const NvBlastAssetDesc *desc, void *scratch, NvBlastLog logFn)
NvBlastBlockArrayData(NvBlastChunk, m_chunksOffset, getChunks, m_chunkCount)
-
NvBlastID m_ID
Definition: NvBlastAsset.h:186
-
uint32_t getUpperSupportChunkCount() const
Definition: NvBlastAsset.h:264
-
uint32_t getHierarchyCount() const
Definition: NvBlastAsset.h:283
-
uint32_t m_chunkCount
Definition: NvBlastAsset.h:191
+
NvBlastID m_ID
Definition: NvBlastAsset.h:187
+
uint32_t getUpperSupportChunkCount() const
Definition: NvBlastAsset.h:265
+
uint32_t getHierarchyCount() const
Definition: NvBlastAsset.h:284
+
uint32_t m_chunkCount
Definition: NvBlastAsset.h:192
Definition: NvBlastAsset.h:57
Definition: NvBlastArray.h:37
diff --git a/docs/source_docs/files/_nv_blast_ext_authoring_boolean_tool_8h_source.html b/docs/source_docs/files/_nv_blast_ext_authoring_boolean_tool_8h_source.html index 6f94473..0b48ae9 100755 --- a/docs/source_docs/files/_nv_blast_ext_authoring_boolean_tool_8h_source.html +++ b/docs/source_docs/files/_nv_blast_ext_authoring_boolean_tool_8h_source.html @@ -49,7 +49,7 @@ $(document).ready(function(){initNavTree('_nv_blast_ext_authoring_boolean_tool_8 Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTEXTAUTHORINGBOOLEANTOOL_H
30 #define NVBLASTEXTAUTHORINGBOOLEANTOOL_H
31 
34 #include <vector>
35 #include "NvBlastTypes.h"
36 
37 
38 namespace Nv
39 {
40 namespace Blast
41 {
42 
43 class Mesh;
44 
49 {
50  int32_t ca, cb, ci;
51  BooleanConf(int32_t a, int32_t b, int32_t c) : ca(a), cb(b), ci(c)
52  {
53  }
54 };
55 
56 
57 namespace BooleanConfigurations
58 {
63 {
64  return BooleanConf(0, 0, 1);
65 }
66 
71 {
72  return BooleanConf(1, 1, -1);
73 }
78 {
79  return BooleanConf(1, 0, -1);
80 }
81 }
82 
87 {
88  int32_t edId;
91  EdgeFacetIntersectionData(int32_t edId, int32_t intersType, Vertex& inters) : edId(edId), intersectionType(intersType), intersectionPoint(inters)
92  { }
93  EdgeFacetIntersectionData(int32_t edId) : edId(edId)
94  { }
95  bool operator<(const EdgeFacetIntersectionData& b) const
96  {
97  return edId < b.edId;
98  }
99 };
100 
101 
102 class SpatialAccelerator;
103 
109 {
110 
111 public:
113  ~BooleanEvaluator();
114 
123  void performBoolean(const Mesh* meshA, const Mesh* meshB, SpatialAccelerator* spAccelA, SpatialAccelerator* spAccelB, BooleanConf mode);
124 
131  void performBoolean(const Mesh* meshA, const Mesh* meshB, BooleanConf mode);
132 
142  void performFastCutting(const Mesh* meshA, const Mesh* meshB, SpatialAccelerator* spAccelA, SpatialAccelerator* spAccelB, BooleanConf mode);
143 
151  void performFastCutting(const Mesh* meshA, const Mesh* meshB, BooleanConf mode);
152 
159  int32_t isPointContainedInMesh(const Mesh* mesh, const NvcVec3& point);
167  int32_t isPointContainedInMesh(const Mesh* mesh, SpatialAccelerator* spAccel, const NvcVec3& point);
168 
169 
174  Mesh* createNewMesh();
175 
179  void reset();
180 
181 private:
182 
183  void buildFaceFaceIntersections(BooleanConf);
184  void buildFastFaceFaceIntersection(BooleanConf);
185  void collectRetainedPartsFromA(BooleanConf mode);
186  void collectRetainedPartsFromB(BooleanConf mode);
187 
188  int32_t addIfNotExist(Vertex& p);
189  void addEdgeIfValid(EdgeWithParent& ed);
190 private:
191 
192  int32_t vertexMeshStatus03(const NvcVec3& p, const Mesh* mesh);
193  int32_t vertexMeshStatus30(const NvcVec3& p, const Mesh* mesh);
194 
195  const Mesh* mMeshA;
196  const Mesh* mMeshB;
197 
198  SpatialAccelerator* mAcceleratorA;
199  SpatialAccelerator* mAcceleratorB;
200 
201  std::vector<EdgeWithParent> mEdgeAggregate;
202  std::vector<Vertex> mVerticesAggregate;
203 
204  std::vector<std::vector<EdgeFacetIntersectionData> > mEdgeFacetIntersectionData12;
205  std::vector<std::vector<EdgeFacetIntersectionData> > mEdgeFacetIntersectionData21;
206 };
207 
208 } // namespace Blast
209 } // namespace Nv
210 
211 
212 #endif // ifndef NVBLASTEXTAUTHORINGBOOLEANTOOL_H
Vertex intersectionPoint
Definition: NvBlastExtAuthoringBooleanTool.h:90
Definition: NvBlastExtAuthoringBooleanTool.h:108
-
Definition: NvBlastExtAuthoringInternalCommon.h:47
+
Definition: NvBlastExtAuthoringInternalCommon.h:48
EdgeFacetIntersectionData(int32_t edId)
Definition: NvBlastExtAuthoringBooleanTool.h:93
Definition: NvBlastExtAuthoringAccelerator.h:47
diff --git a/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_8h-source.html b/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_8h-source.html index b3703bc..e8cc7dc 100755 --- a/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_8h-source.html +++ b/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_8h-source.html @@ -86,8 +86,8 @@ 00048 { 00049 enum ChunkFlags 00050 { -00051 NO_FLAGS = 0, -00052 CREATED_BY_ISLAND_DETECTOR = 1 +00051 NO_FLAGS = 0, +00052 APPROXIMATE_BONDING = 1 // Created by island splitting or chunk merge, etc. and should check for inexact bonds 00053 }; 00054 00055 Mesh* meshData; @@ -262,15 +262,17 @@ 00512 const NvcVec2i* adjChunks, uint32_t adjChunksSize, 00513 bool removeOriginalChunks = false) = 0; 00514 -00520 virtual void fitUvToRect(float side, uint32_t chunkId) = 0; -00521 -00526 virtual void fitAllUvToRect(float side) = 0; -00527 }; -00528 -00529 } // namespace Blast -00530 } // namespace Nv -00531 -00532 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOL_H +00521 virtual bool setApproximateBonding(uint32_t chunkIndex, bool useApproximateBonding) = 0; +00522 +00528 virtual void fitUvToRect(float side, uint32_t chunkId) = 0; +00529 +00534 virtual void fitAllUvToRect(float side) = 0; +00535 }; +00536 +00537 } // namespace Blast +00538 } // namespace Nv +00539 +00540 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOL_H
-Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTAUTHORINGFRACTURETOOL_H
30 #define NVBLASTAUTHORINGFRACTURETOOL_H
31 
33 
34 namespace Nv
35 {
36 namespace Blast
37 {
38 
39 class SpatialAccelerator;
40 class Triangulator;
41 class Mesh;
42 class CutoutSet;
43 
44 /*
45  Chunk data, chunk with chunkId == 0 is always source mesh.
46 */
47 struct ChunkInfo
48 {
50  {
51  NO_FLAGS = 0,
53  };
54 
56  int32_t parent;
57  int32_t chunkId;
58  uint32_t flags;
59  bool isLeaf;
60  bool isChanged;
61 };
62 
67 {
68  public:
69  // Generates uniformly distributed value in [0, 1] range.
70  virtual float getRandomValue() = 0;
71  // Seeds random value generator
72  virtual void seed(int32_t seed) = 0;
73  virtual ~RandomGeneratorBase(){};
74 };
75 
76 /*
77  Noise fracturing configuration for chunks's faces
78 */
80 {
86  float amplitude = 0.f;
87 
91  float frequency = 1.f;
92 
96  uint32_t octaveNumber = 1;
97 
101  NvcVec3 samplingInterval = { 1, 1, 1 };
102 };
103 
104 /*
105  Slicing fracturing configuration
106 */
108 {
112  int32_t x_slices = 1, y_slices = 1, z_slices = 1;
113 
117  float offset_variations = 0.f;
118 
122  float angle_variations = 0.f;
123 
124  /*
125  Noise parameters for faces between sliced chunks
126  */
128 };
129 
134 {
139  CutoutSet* cutoutSet = nullptr;
140 
145  NvcTransform transform = {{0, 0, 0, 1}, {0, 0, 0}};
146 
152  NvcVec2 scale = { -1, -1 };
153 
157  float aperture = 0.f;
158 
163  bool isRelativeTransform = true;
164 
168  bool useSmoothing = false;
169 
174 };
175 
180 {
181  public:
183 
187  virtual void release() = 0;
188 
192  virtual void setBaseMesh(const Mesh* mesh) = 0;
193 
199  virtual uint32_t getVoronoiSites(const NvcVec3*& sites) = 0;
200 
205  virtual void addSite(const NvcVec3& site) = 0;
210  virtual void uniformlyGenerateSitesInMesh(uint32_t numberOfSites) = 0;
211 
218  virtual void clusteredSitesGeneration(uint32_t numberOfClusters, uint32_t sitesPerCluster, float clusterRadius) = 0;
219 
230  virtual void radialPattern(const NvcVec3& center, const NvcVec3& normal, float radius, int32_t angularSteps,
231  int32_t radialSteps, float angleOffset = 0.0f, float variability = 0.0f) = 0;
232 
239  virtual void generateInSphere(const uint32_t count, const float radius, const NvcVec3& center) = 0;
240 
245  virtual void setStencil(const Mesh* stencil) = 0;
246 
250  virtual void clearStencil() = 0;
251 
258  virtual void deleteInSphere(const float radius, const NvcVec3& center, const float eraserProbability = 1) = 0;
259 };
260 
265 {
266 
267  public:
268  virtual ~FractureTool() {}
269 
273  virtual void release() = 0;
274 
278  virtual void reset() = 0;
279 
280 
284  virtual void setSourceMesh(const Mesh* mesh) = 0;
285 
289  virtual int32_t setChunkMesh(const Mesh* mesh, int32_t parentId) = 0;
290 
294  virtual void setInteriorMaterialId(int32_t materialId) = 0;
295 
299  virtual int32_t getInteriorMaterialId() const = 0;
300 
304  virtual void replaceMaterialId(int32_t oldMaterialId, int32_t newMaterialId) = 0;
305 
309  virtual Mesh* createChunkMesh(int32_t chunkId) = 0;
310 
315  virtual void getTransformation(NvcVec3& offset, float& scale) = 0;
316 
317 
326  virtual int32_t
327  voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints, bool replaceChunk) = 0;
328 
340  virtual int32_t voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints,
341  const NvcVec3& scale, const NvcQuat& rotation, bool replaceChunk) = 0;
342 
343 
355  virtual int32_t
356  slicing(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd) = 0;
357 
371  virtual int32_t cut(uint32_t chunkId, const NvcVec3& normal, const NvcVec3& position,
372  const NoiseConfiguration& noise, bool replaceChunk, RandomGeneratorBase* rnd) = 0;
373 
385  virtual int32_t cutout(uint32_t chunkId, CutoutConfiguration conf, bool replaceChunk, RandomGeneratorBase* rnd) = 0;
386 
387 
391  virtual void finalizeFracturing() = 0;
392 
396  virtual uint32_t getChunkCount() const = 0;
397 
401  virtual const ChunkInfo& getChunkInfo(int32_t chunkIndex) = 0;
402 
410  virtual float getMeshOverlap(const Mesh& meshA, const Mesh& meshB) = 0;
411 
418  virtual uint32_t getBaseMesh(int32_t chunkIndex, Triangle*& output) = 0;
419 
427  virtual uint32_t updateBaseMesh(int32_t chunkIndex, Triangle* output) = 0;
428 
434  virtual int32_t getChunkIndex(int32_t chunkId) = 0;
435 
441  virtual int32_t getChunkId(int32_t chunkIndex) = 0;
442 
448  virtual int32_t getChunkDepth(int32_t chunkId) = 0;
449 
456  virtual uint32_t getChunksIdAtDepth(uint32_t depth, int32_t*& chunkIds) = 0;
457 
467  virtual uint32_t
468  getBufferedBaseMeshes(Vertex*& vertexBuffer, uint32_t*& indexBuffer, uint32_t*& indexBufferOffsets) = 0;
469 
474  virtual void setRemoveIslands(bool isRemoveIslands) = 0;
475 
481  virtual int32_t islandDetectionAndRemoving(int32_t chunkId, bool createAtNewDepth = false) = 0;
482 
487  virtual bool isMeshContainOpenEdges(const Mesh* input) = 0;
488 
495  virtual bool deleteChunkSubhierarchy(int32_t chunkId, bool deleteRoot = false) = 0;
496 
510  virtual void uniteChunks(uint32_t threshold, uint32_t targetClusterSize,
511  const uint32_t* chunksToMerge, uint32_t mergeChunkCount,
512  const NvcVec2i* adjChunks, uint32_t adjChunksSize,
513  bool removeOriginalChunks = false) = 0;
514 
520  virtual void fitUvToRect(float side, uint32_t chunkId) = 0;
521 
526  virtual void fitAllUvToRect(float side) = 0;
527 };
528 
529 } // namespace Blast
530 } // namespace Nv
531 
532 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOL_H
Definition: NvBlastExtAuthoringFractureTool.h:107
+Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTAUTHORINGFRACTURETOOL_H
30 #define NVBLASTAUTHORINGFRACTURETOOL_H
31 
33 
34 namespace Nv
35 {
36 namespace Blast
37 {
38 
39 class SpatialAccelerator;
40 class Triangulator;
41 class Mesh;
42 class CutoutSet;
43 
44 /*
45  Chunk data, chunk with chunkId == 0 is always source mesh.
46 */
47 struct ChunkInfo
48 {
50  {
51  NO_FLAGS = 0,
52  APPROXIMATE_BONDING = 1 // Created by island splitting or chunk merge, etc. and should check for inexact bonds
53  };
54 
56  int32_t parent;
57  int32_t chunkId;
58  uint32_t flags;
59  bool isLeaf;
60  bool isChanged;
61 };
62 
67 {
68  public:
69  // Generates uniformly distributed value in [0, 1] range.
70  virtual float getRandomValue() = 0;
71  // Seeds random value generator
72  virtual void seed(int32_t seed) = 0;
73  virtual ~RandomGeneratorBase(){};
74 };
75 
76 /*
77  Noise fracturing configuration for chunks's faces
78 */
80 {
86  float amplitude = 0.f;
87 
91  float frequency = 1.f;
92 
96  uint32_t octaveNumber = 1;
97 
101  NvcVec3 samplingInterval = { 1, 1, 1 };
102 };
103 
104 /*
105  Slicing fracturing configuration
106 */
108 {
112  int32_t x_slices = 1, y_slices = 1, z_slices = 1;
113 
117  float offset_variations = 0.f;
118 
122  float angle_variations = 0.f;
123 
124  /*
125  Noise parameters for faces between sliced chunks
126  */
128 };
129 
134 {
139  CutoutSet* cutoutSet = nullptr;
140 
145  NvcTransform transform = {{0, 0, 0, 1}, {0, 0, 0}};
146 
152  NvcVec2 scale = { -1, -1 };
153 
157  float aperture = 0.f;
158 
163  bool isRelativeTransform = true;
164 
168  bool useSmoothing = false;
169 
174 };
175 
180 {
181  public:
183 
187  virtual void release() = 0;
188 
192  virtual void setBaseMesh(const Mesh* mesh) = 0;
193 
199  virtual uint32_t getVoronoiSites(const NvcVec3*& sites) = 0;
200 
205  virtual void addSite(const NvcVec3& site) = 0;
210  virtual void uniformlyGenerateSitesInMesh(uint32_t numberOfSites) = 0;
211 
218  virtual void clusteredSitesGeneration(uint32_t numberOfClusters, uint32_t sitesPerCluster, float clusterRadius) = 0;
219 
230  virtual void radialPattern(const NvcVec3& center, const NvcVec3& normal, float radius, int32_t angularSteps,
231  int32_t radialSteps, float angleOffset = 0.0f, float variability = 0.0f) = 0;
232 
239  virtual void generateInSphere(const uint32_t count, const float radius, const NvcVec3& center) = 0;
240 
245  virtual void setStencil(const Mesh* stencil) = 0;
246 
250  virtual void clearStencil() = 0;
251 
258  virtual void deleteInSphere(const float radius, const NvcVec3& center, const float eraserProbability = 1) = 0;
259 };
260 
265 {
266 
267  public:
268  virtual ~FractureTool() {}
269 
273  virtual void release() = 0;
274 
278  virtual void reset() = 0;
279 
280 
284  virtual void setSourceMesh(const Mesh* mesh) = 0;
285 
289  virtual int32_t setChunkMesh(const Mesh* mesh, int32_t parentId) = 0;
290 
294  virtual void setInteriorMaterialId(int32_t materialId) = 0;
295 
299  virtual int32_t getInteriorMaterialId() const = 0;
300 
304  virtual void replaceMaterialId(int32_t oldMaterialId, int32_t newMaterialId) = 0;
305 
309  virtual Mesh* createChunkMesh(int32_t chunkId) = 0;
310 
315  virtual void getTransformation(NvcVec3& offset, float& scale) = 0;
316 
317 
326  virtual int32_t
327  voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints, bool replaceChunk) = 0;
328 
340  virtual int32_t voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints,
341  const NvcVec3& scale, const NvcQuat& rotation, bool replaceChunk) = 0;
342 
343 
355  virtual int32_t
356  slicing(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd) = 0;
357 
371  virtual int32_t cut(uint32_t chunkId, const NvcVec3& normal, const NvcVec3& position,
372  const NoiseConfiguration& noise, bool replaceChunk, RandomGeneratorBase* rnd) = 0;
373 
385  virtual int32_t cutout(uint32_t chunkId, CutoutConfiguration conf, bool replaceChunk, RandomGeneratorBase* rnd) = 0;
386 
387 
391  virtual void finalizeFracturing() = 0;
392 
396  virtual uint32_t getChunkCount() const = 0;
397 
401  virtual const ChunkInfo& getChunkInfo(int32_t chunkIndex) = 0;
402 
410  virtual float getMeshOverlap(const Mesh& meshA, const Mesh& meshB) = 0;
411 
418  virtual uint32_t getBaseMesh(int32_t chunkIndex, Triangle*& output) = 0;
419 
427  virtual uint32_t updateBaseMesh(int32_t chunkIndex, Triangle* output) = 0;
428 
434  virtual int32_t getChunkIndex(int32_t chunkId) = 0;
435 
441  virtual int32_t getChunkId(int32_t chunkIndex) = 0;
442 
448  virtual int32_t getChunkDepth(int32_t chunkId) = 0;
449 
456  virtual uint32_t getChunksIdAtDepth(uint32_t depth, int32_t*& chunkIds) = 0;
457 
467  virtual uint32_t
468  getBufferedBaseMeshes(Vertex*& vertexBuffer, uint32_t*& indexBuffer, uint32_t*& indexBufferOffsets) = 0;
469 
474  virtual void setRemoveIslands(bool isRemoveIslands) = 0;
475 
481  virtual int32_t islandDetectionAndRemoving(int32_t chunkId, bool createAtNewDepth = false) = 0;
482 
487  virtual bool isMeshContainOpenEdges(const Mesh* input) = 0;
488 
495  virtual bool deleteChunkSubhierarchy(int32_t chunkId, bool deleteRoot = false) = 0;
496 
510  virtual void uniteChunks(uint32_t threshold, uint32_t targetClusterSize,
511  const uint32_t* chunksToMerge, uint32_t mergeChunkCount,
512  const NvcVec2i* adjChunks, uint32_t adjChunksSize,
513  bool removeOriginalChunks = false) = 0;
514 
521  virtual bool setApproximateBonding(uint32_t chunkIndex, bool useApproximateBonding) = 0;
522 
528  virtual void fitUvToRect(float side, uint32_t chunkId) = 0;
529 
534  virtual void fitAllUvToRect(float side) = 0;
535 };
536 
537 } // namespace Blast
538 } // namespace Nv
539 
540 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOL_H
Definition: NvBlastExtAuthoringFractureTool.h:107
Definition: NvBlastExtAuthoringFractureTool.h:47
Definition: NvBlastExtAuthoringFractureTool.h:179
-
Definition: NvBlastExtAuthoringFractureTool.h:52
NV_INLINE float normal(const float a[3], float r[3])
Definition: NvBlastMath.h:93
Definition: NvBlastExtAuthoringCutout.h:36
+
Definition: NvBlastExtAuthoringFractureTool.h:52
Definition: NvBlastExtAuthoringFractureTool.h:79
Definition: NvBlastExtAuthoringMesh.h:42
diff --git a/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_impl_8h-source.html b/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_impl_8h-source.html index 4bb26eb..b413c20 100755 --- a/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_impl_8h-source.html +++ b/docs/source_docs/files/_nv_blast_ext_authoring_fracture_tool_impl_8h-source.html @@ -202,49 +202,51 @@ 00380 const NvcVec2i* adjChunks, uint32_t adjChunksSize, 00381 bool removeOriginalChunks = false) override; 00382 -00383 -00389 void fitUvToRect(float side, uint32_t chunkId) override; -00390 -00395 void fitAllUvToRect(float side) override; -00396 +00383 bool setApproximateBonding(uint32_t chunkId, bool useApproximateBonding) override; +00384 +00390 void fitUvToRect(float side, uint32_t chunkId) override; +00391 +00396 void fitAllUvToRect(float side) override; 00397 00398 -00399 private: -00400 bool isAncestorForChunk(int32_t ancestorId, int32_t chunkId); -00401 int32_t slicingNoisy(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd); -00402 uint32_t stretchGroup(const std::vector<uint32_t>& group, std::vector<std::vector<uint32_t>>& graph); -00403 void rebuildAdjGraph(const std::vector<uint32_t>& chunksToRebuild, const NvcVec2i* adjChunks, uint32_t adjChunksSize, -00404 std::vector<std::vector<uint32_t> >& chunkGraph); -00405 void fitAllUvToRect(float side, std::set<uint32_t>& mask); -00406 -00410 uint32_t createNewChunk(uint32_t parentId); -00411 -00412 -00413 protected: -00417 float mScaleFactor; -00418 NvcVec3 mOffset; -00419 -00420 /* Chunk mesh wrappers */ -00421 std::vector<Triangulator*> mChunkPostprocessors; -00422 -00423 -00424 -00425 int64_t mPlaneIndexerOffset; -00426 int32_t mChunkIdCounter; -00427 std::vector<ChunkInfo> mChunkData; -00428 -00429 bool mRemoveIslands; -00430 int32_t mInteriorMaterialId; -00431 }; -00432 -00433 void findCellBasePlanes(const std::vector<NvcVec3>& sites, std::vector<std::vector<int32_t> >& neighboors); -00434 Mesh* getCellMesh(class BooleanEvaluator& eval, int32_t planeIndexerOffset, int32_t cellId, const std::vector<NvcVec3>& sites, std::vector < std::vector<int32_t> >& neighboors, int32_t interiorMaterialId, NvcVec3 origin); -00435 -00436 } // namespace Blast -00437 } // namespace Nv -00438 -00439 -00440 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOLIMPL_H +00399 +00400 private: +00401 bool isAncestorForChunk(int32_t ancestorId, int32_t chunkId); +00402 int32_t slicingNoisy(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd); +00403 uint32_t stretchGroup(const std::vector<uint32_t>& group, std::vector<std::vector<uint32_t>>& graph); +00404 void rebuildAdjGraph(const std::vector<uint32_t>& chunksToRebuild, const NvcVec2i* adjChunks, uint32_t adjChunksSize, +00405 std::vector<std::vector<uint32_t> >& chunkGraph); +00406 void fitAllUvToRect(float side, std::set<uint32_t>& mask); +00407 void markLeaves(); +00408 +00412 uint32_t createNewChunk(uint32_t parentId); +00413 +00414 +00415 protected: +00419 float mScaleFactor; +00420 NvcVec3 mOffset; +00421 +00422 /* Chunk mesh wrappers */ +00423 std::vector<Triangulator*> mChunkPostprocessors; +00424 +00425 +00426 +00427 int64_t mPlaneIndexerOffset; +00428 int32_t mChunkIdCounter; +00429 std::vector<ChunkInfo> mChunkData; +00430 +00431 bool mRemoveIslands; +00432 int32_t mInteriorMaterialId; +00433 }; +00434 +00435 void findCellBasePlanes(const std::vector<NvcVec3>& sites, std::vector<std::vector<int32_t> >& neighboors); +00436 Mesh* getCellMesh(class BooleanEvaluator& eval, int32_t planeIndexerOffset, int32_t cellId, const std::vector<NvcVec3>& sites, std::vector < std::vector<int32_t> >& neighboors, int32_t interiorMaterialId, NvcVec3 origin); +00437 +00438 } // namespace Blast +00439 } // namespace Nv +00440 +00441 +00442 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOLIMPL_H
-Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 #ifndef NVBLASTAUTHORINGFRACTURETOOLIMPL_H
29 #define NVBLASTAUTHORINGFRACTURETOOLIMPL_H
30 
33 #include <vector>
34 #include <set>
35 
36 namespace Nv
37 {
38 namespace Blast
39 {
40 
41 class SpatialAccelerator;
42 class Triangulator;
43 
44 
49 {
50 public:
51 
61 
62  void release() override;
63 
67  void setBaseMesh(const Mesh* m) override;
68 
75  uint32_t getVoronoiSites(const NvcVec3*& sites) override;
76 
81  void addSite(const NvcVec3& site) override;
86  void uniformlyGenerateSitesInMesh(uint32_t numberOfSites) override;
87 
94  void clusteredSitesGeneration(uint32_t numberOfClusters, uint32_t sitesPerCluster, float clusterRadius) override;
95 
106  void radialPattern(const NvcVec3& center, const NvcVec3& normal, float radius, int32_t angularSteps, int32_t radialSteps, float angleOffset = 0.0f, float variability = 0.0f) override;
107 
114  void generateInSphere(const uint32_t count, const float radius, const NvcVec3& center) override;
119  void setStencil(const Mesh* stencil) override;
123  void clearStencil() override;
124 
131  void deleteInSphere(const float radius, const NvcVec3& center, const float eraserProbability = 1) override;
132 
133 private:
134  std::vector <NvcVec3> mGeneratedSites;
135  const Mesh* mMesh;
136  const Mesh* mStencil;
137  RandomGeneratorBase* mRnd;
138  SpatialAccelerator* mAccelerator;
139 };
140 
141 
142 
147 {
148 
149 public:
150 
155  {
156  mPlaneIndexerOffset = 1;
157  mChunkIdCounter = 0;
158  mRemoveIslands = false;
159  mInteriorMaterialId = kMaterialInteriorId;
160  }
161 
163  {
164  reset();
165  }
166 
167  void release() override;
168 
172  void reset() override;
173 
177  void setInteriorMaterialId(int32_t materialId) override;
178 
182  int32_t getInteriorMaterialId() const override;
183 
187  void replaceMaterialId(int32_t oldMaterialId, int32_t newMaterialId) override;
188 
192  void setSourceMesh(const Mesh* mesh) override;
193 
197  int32_t setChunkMesh(const Mesh* mesh, int32_t parentId) override;
198 
202  Mesh* createChunkMesh(int32_t chunkId) override;
203 
208  void getTransformation(NvcVec3& offset, float& scale) override;
209 
210 
219  int32_t voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints, bool replaceChunk) override;
220 
232  int32_t voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints, const NvcVec3& scale, const NvcQuat& rotation, bool replaceChunk) override;
233 
234 
245  int32_t slicing(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd) override;
246 
247 
260  int32_t cut(uint32_t chunkId, const NvcVec3& normal, const NvcVec3& position, const NoiseConfiguration& noise, bool replaceChunk, RandomGeneratorBase* rnd) override;
261 
272  int32_t cutout(uint32_t chunkId, CutoutConfiguration conf, bool replaceChunk, RandomGeneratorBase* rnd) override;
273 
274 
278  void finalizeFracturing() override;
279 
280  uint32_t getChunkCount() const override;
281 
285  const ChunkInfo& getChunkInfo(int32_t chunkIndex) override;
286 
294  float getMeshOverlap(const Mesh& meshA, const Mesh& meshB) override;
295 
303  uint32_t getBaseMesh(int32_t chunkIndex, Triangle*& output) override;
304 
312  uint32_t updateBaseMesh(int32_t chunkIndex, Triangle* output) override;
313 
319  int32_t getChunkIndex(int32_t chunkId) override;
320 
326  int32_t getChunkId(int32_t chunkIndex) override;
327 
333  int32_t getChunkDepth(int32_t chunkId) override;
334 
342  uint32_t getChunksIdAtDepth(uint32_t depth, int32_t*& chunkIds) override;
343 
344 
355  uint32_t getBufferedBaseMeshes(Vertex*& vertexBuffer, uint32_t*& indexBuffer, uint32_t*& indexBufferOffsets) override;
356 
361  void setRemoveIslands(bool isRemoveIslands) override;
362 
368  int32_t islandDetectionAndRemoving(int32_t chunkId, bool createAtNewDepth = false) override;
369 
374  bool isMeshContainOpenEdges(const Mesh* input) override;
375 
376  bool deleteChunkSubhierarchy(int32_t chunkId, bool deleteRoot = false) override;
377 
378  void uniteChunks(uint32_t threshold, uint32_t targetClusterSize,
379  const uint32_t* chunksToMerge, uint32_t mergeChunkCount,
380  const NvcVec2i* adjChunks, uint32_t adjChunksSize,
381  bool removeOriginalChunks = false) override;
382 
383 
389  void fitUvToRect(float side, uint32_t chunkId) override;
390 
395  void fitAllUvToRect(float side) override;
396 
397 
398 
399 private:
400  bool isAncestorForChunk(int32_t ancestorId, int32_t chunkId);
401  int32_t slicingNoisy(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd);
402  uint32_t stretchGroup(const std::vector<uint32_t>& group, std::vector<std::vector<uint32_t>>& graph);
403  void rebuildAdjGraph(const std::vector<uint32_t>& chunksToRebuild, const NvcVec2i* adjChunks, uint32_t adjChunksSize,
404  std::vector<std::vector<uint32_t> >& chunkGraph);
405  void fitAllUvToRect(float side, std::set<uint32_t>& mask);
406 
410  uint32_t createNewChunk(uint32_t parentId);
411 
412 
413 protected:
419 
420  /* Chunk mesh wrappers */
421  std::vector<Triangulator*> mChunkPostprocessors;
422 
423 
424 
427  std::vector<ChunkInfo> mChunkData;
428 
431 };
432 
433 void findCellBasePlanes(const std::vector<NvcVec3>& sites, std::vector<std::vector<int32_t> >& neighboors);
434 Mesh* getCellMesh(class BooleanEvaluator& eval, int32_t planeIndexerOffset, int32_t cellId, const std::vector<NvcVec3>& sites, std::vector < std::vector<int32_t> >& neighboors, int32_t interiorMaterialId, NvcVec3 origin);
435 
436 } // namespace Blast
437 } // namespace Nv
438 
439 
440 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOLIMPL_H
Definition: NvBlastExtAuthoringFractureTool.h:107
+Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 #ifndef NVBLASTAUTHORINGFRACTURETOOLIMPL_H
29 #define NVBLASTAUTHORINGFRACTURETOOLIMPL_H
30 
33 #include <vector>
34 #include <set>
35 
36 namespace Nv
37 {
38 namespace Blast
39 {
40 
41 class SpatialAccelerator;
42 class Triangulator;
43 
44 
49 {
50 public:
51 
61 
62  void release() override;
63 
67  void setBaseMesh(const Mesh* m) override;
68 
75  uint32_t getVoronoiSites(const NvcVec3*& sites) override;
76 
81  void addSite(const NvcVec3& site) override;
86  void uniformlyGenerateSitesInMesh(uint32_t numberOfSites) override;
87 
94  void clusteredSitesGeneration(uint32_t numberOfClusters, uint32_t sitesPerCluster, float clusterRadius) override;
95 
106  void radialPattern(const NvcVec3& center, const NvcVec3& normal, float radius, int32_t angularSteps, int32_t radialSteps, float angleOffset = 0.0f, float variability = 0.0f) override;
107 
114  void generateInSphere(const uint32_t count, const float radius, const NvcVec3& center) override;
119  void setStencil(const Mesh* stencil) override;
123  void clearStencil() override;
124 
131  void deleteInSphere(const float radius, const NvcVec3& center, const float eraserProbability = 1) override;
132 
133 private:
134  std::vector <NvcVec3> mGeneratedSites;
135  const Mesh* mMesh;
136  const Mesh* mStencil;
137  RandomGeneratorBase* mRnd;
138  SpatialAccelerator* mAccelerator;
139 };
140 
141 
142 
147 {
148 
149 public:
150 
155  {
156  mPlaneIndexerOffset = 1;
157  mChunkIdCounter = 0;
158  mRemoveIslands = false;
159  mInteriorMaterialId = kMaterialInteriorId;
160  }
161 
163  {
164  reset();
165  }
166 
167  void release() override;
168 
172  void reset() override;
173 
177  void setInteriorMaterialId(int32_t materialId) override;
178 
182  int32_t getInteriorMaterialId() const override;
183 
187  void replaceMaterialId(int32_t oldMaterialId, int32_t newMaterialId) override;
188 
192  void setSourceMesh(const Mesh* mesh) override;
193 
197  int32_t setChunkMesh(const Mesh* mesh, int32_t parentId) override;
198 
202  Mesh* createChunkMesh(int32_t chunkId) override;
203 
208  void getTransformation(NvcVec3& offset, float& scale) override;
209 
210 
219  int32_t voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints, bool replaceChunk) override;
220 
232  int32_t voronoiFracturing(uint32_t chunkId, uint32_t cellCount, const NvcVec3* cellPoints, const NvcVec3& scale, const NvcQuat& rotation, bool replaceChunk) override;
233 
234 
245  int32_t slicing(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd) override;
246 
247 
260  int32_t cut(uint32_t chunkId, const NvcVec3& normal, const NvcVec3& position, const NoiseConfiguration& noise, bool replaceChunk, RandomGeneratorBase* rnd) override;
261 
272  int32_t cutout(uint32_t chunkId, CutoutConfiguration conf, bool replaceChunk, RandomGeneratorBase* rnd) override;
273 
274 
278  void finalizeFracturing() override;
279 
280  uint32_t getChunkCount() const override;
281 
285  const ChunkInfo& getChunkInfo(int32_t chunkIndex) override;
286 
294  float getMeshOverlap(const Mesh& meshA, const Mesh& meshB) override;
295 
303  uint32_t getBaseMesh(int32_t chunkIndex, Triangle*& output) override;
304 
312  uint32_t updateBaseMesh(int32_t chunkIndex, Triangle* output) override;
313 
319  int32_t getChunkIndex(int32_t chunkId) override;
320 
326  int32_t getChunkId(int32_t chunkIndex) override;
327 
333  int32_t getChunkDepth(int32_t chunkId) override;
334 
342  uint32_t getChunksIdAtDepth(uint32_t depth, int32_t*& chunkIds) override;
343 
344 
355  uint32_t getBufferedBaseMeshes(Vertex*& vertexBuffer, uint32_t*& indexBuffer, uint32_t*& indexBufferOffsets) override;
356 
361  void setRemoveIslands(bool isRemoveIslands) override;
362 
368  int32_t islandDetectionAndRemoving(int32_t chunkId, bool createAtNewDepth = false) override;
369 
374  bool isMeshContainOpenEdges(const Mesh* input) override;
375 
376  bool deleteChunkSubhierarchy(int32_t chunkId, bool deleteRoot = false) override;
377 
378  void uniteChunks(uint32_t threshold, uint32_t targetClusterSize,
379  const uint32_t* chunksToMerge, uint32_t mergeChunkCount,
380  const NvcVec2i* adjChunks, uint32_t adjChunksSize,
381  bool removeOriginalChunks = false) override;
382 
383  bool setApproximateBonding(uint32_t chunkId, bool useApproximateBonding) override;
384 
390  void fitUvToRect(float side, uint32_t chunkId) override;
391 
396  void fitAllUvToRect(float side) override;
397 
398 
399 
400 private:
401  bool isAncestorForChunk(int32_t ancestorId, int32_t chunkId);
402  int32_t slicingNoisy(uint32_t chunkId, const SlicingConfiguration& conf, bool replaceChunk, RandomGeneratorBase* rnd);
403  uint32_t stretchGroup(const std::vector<uint32_t>& group, std::vector<std::vector<uint32_t>>& graph);
404  void rebuildAdjGraph(const std::vector<uint32_t>& chunksToRebuild, const NvcVec2i* adjChunks, uint32_t adjChunksSize,
405  std::vector<std::vector<uint32_t> >& chunkGraph);
406  void fitAllUvToRect(float side, std::set<uint32_t>& mask);
407  void markLeaves();
408 
412  uint32_t createNewChunk(uint32_t parentId);
413 
414 
415 protected:
421 
422  /* Chunk mesh wrappers */
423  std::vector<Triangulator*> mChunkPostprocessors;
424 
425 
426 
429  std::vector<ChunkInfo> mChunkData;
430 
433 };
434 
435 void findCellBasePlanes(const std::vector<NvcVec3>& sites, std::vector<std::vector<int32_t> >& neighboors);
436 Mesh* getCellMesh(class BooleanEvaluator& eval, int32_t planeIndexerOffset, int32_t cellId, const std::vector<NvcVec3>& sites, std::vector < std::vector<int32_t> >& neighboors, int32_t interiorMaterialId, NvcVec3 origin);
437 
438 } // namespace Blast
439 } // namespace Nv
440 
441 
442 #endif // ifndef NVBLASTAUTHORINGFRACTURETOOLIMPL_H
Definition: NvBlastExtAuthoringFractureTool.h:107
void generateInSphere(const uint32_t count, const float radius, const NvcVec3 &center) override
Definition: NvBlastExtAuthoringFractureTool.h:47
uint32_t getVoronoiSites(const NvcVec3 *&sites) override
@@ -57,7 +57,7 @@ $(document).ready(function(){initNavTree('_nv_blast_ext_authoring_fracture_tool_
Definition: NvBlastExtAuthoringBooleanTool.h:108
NV_INLINE float normal(const float a[3], float r[3])
Definition: NvBlastMath.h:93
void setBaseMesh(const Mesh *m) override
-
float mScaleFactor
Definition: NvBlastExtAuthoringFractureToolImpl.h:417
+
float mScaleFactor
Definition: NvBlastExtAuthoringFractureToolImpl.h:419
Definition: NvBlastExtAuthoringAccelerator.h:47
Definition: NvBlastExtAuthoringFractureTool.h:79
@@ -69,15 +69,15 @@ $(document).ready(function(){initNavTree('_nv_blast_ext_authoring_fracture_tool_
void uniformlyGenerateSitesInMesh(uint32_t numberOfSites) override
Mesh * getCellMesh(class BooleanEvaluator &eval, int32_t planeIndexerOffset, int32_t cellId, const std::vector< NvcVec3 > &sites, std::vector< std::vector< int32_t > > &neighboors, int32_t interiorMaterialId, NvcVec3 origin)
-
int32_t mChunkIdCounter
Definition: NvBlastExtAuthoringFractureToolImpl.h:426
+
int32_t mChunkIdCounter
Definition: NvBlastExtAuthoringFractureToolImpl.h:428
Definition: NvCTypes.h:106
const uint32_t kMaterialInteriorId
Definition: NvBlastExtAuthoringTypes.h:42
-
std::vector< ChunkInfo > mChunkData
Definition: NvBlastExtAuthoringFractureToolImpl.h:427
-
std::vector< Triangulator * > mChunkPostprocessors
Definition: NvBlastExtAuthoringFractureToolImpl.h:421
-
NvcVec3 mOffset
Definition: NvBlastExtAuthoringFractureToolImpl.h:418
+
std::vector< ChunkInfo > mChunkData
Definition: NvBlastExtAuthoringFractureToolImpl.h:429
+
std::vector< Triangulator * > mChunkPostprocessors
Definition: NvBlastExtAuthoringFractureToolImpl.h:423
+
NvcVec3 mOffset
Definition: NvBlastExtAuthoringFractureToolImpl.h:420
Definition: NvBlastExtAuthoringFractureTool.h:133
Definition: NvBlastExtAuthoringTypes.h:79
-
int32_t mInteriorMaterialId
Definition: NvBlastExtAuthoringFractureToolImpl.h:430
+
int32_t mInteriorMaterialId
Definition: NvBlastExtAuthoringFractureToolImpl.h:432
Definition: NvBlastExtAuthoringFractureToolImpl.h:48
Definition: NvBlastExtAuthoringFractureToolImpl.h:146
@@ -90,9 +90,9 @@ $(document).ready(function(){initNavTree('_nv_blast_ext_authoring_fracture_tool_
Definition: NvCTypes.h:49
void clusteredSitesGeneration(uint32_t numberOfClusters, uint32_t sitesPerCluster, float clusterRadius) override
-
int64_t mPlaneIndexerOffset
Definition: NvBlastExtAuthoringFractureToolImpl.h:425
+
int64_t mPlaneIndexerOffset
Definition: NvBlastExtAuthoringFractureToolImpl.h:427
Definition: NvCTypes.h:61
-
bool mRemoveIslands
Definition: NvBlastExtAuthoringFractureToolImpl.h:429
+
bool mRemoveIslands
Definition: NvBlastExtAuthoringFractureToolImpl.h:431
diff --git a/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h-source.html b/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h-source.html index d75d734..20d4de3 100755 --- a/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h-source.html +++ b/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h-source.html @@ -67,227 +67,269 @@ 00029 #ifndef NVBLASTINTERNALCOMMON_H 00030 #define NVBLASTINTERNALCOMMON_H 00031 #include "NvBlastExtAuthoringTypes.h" -00032 #include <PxVec2.h> -00033 #include <PxVec3.h> -00034 #include <PxPlane.h> -00035 #include <PxBounds3.h> -00036 #include <PxMath.h> -00037 #include <algorithm> -00038 -00039 namespace Nv -00040 { -00041 namespace Blast -00042 { -00043 -00047 struct EdgeWithParent -00048 { -00049 uint32_t s, e; // Starting and ending vertices -00050 uint32_t parent; // Parent facet index -00051 EdgeWithParent() : s(0), e(0), parent(0) {} -00052 EdgeWithParent(uint32_t s, uint32_t e, uint32_t p) : s(s), e(e), parent(p) {} -00053 }; -00054 +00032 #include "NvBlastPxSharedHelpers.h" +00033 #include <PxVec2.h> +00034 #include <PxVec3.h> +00035 #include <PxPlane.h> +00036 #include <PxBounds3.h> +00037 #include <PxMath.h> +00038 #include <algorithm> +00039 +00040 namespace Nv +00041 { +00042 namespace Blast +00043 { +00044 +00048 struct EdgeWithParent +00049 { +00050 uint32_t s, e; // Starting and ending vertices +00051 uint32_t parent; // Parent facet index +00052 EdgeWithParent() : s(0), e(0), parent(0) {} +00053 EdgeWithParent(uint32_t s, uint32_t e, uint32_t p) : s(s), e(e), parent(p) {} +00054 }; 00055 -00059 struct EdgeComparator -00060 { -00061 bool operator()(const EdgeWithParent& a, const EdgeWithParent& b) const -00062 { -00063 if (a.parent == b.parent) -00064 { -00065 if (a.s == b.s) -00066 { -00067 return a.e < b.e; -00068 } -00069 else -00070 { -00071 return a.s < b.s; -00072 } -00073 } -00074 else -00075 { -00076 return a.parent < b.parent; -00077 } -00078 } -00079 }; -00080 -00081 inline bool operator<(const Edge& a, const Edge& b) -00082 { -00083 if (a.s == b.s) -00084 return a.e < b.e; -00085 else -00086 return a.s < b.s; -00087 } -00088 -00092 enum ProjectionDirections -00093 { -00094 YZ_PLANE = 1 << 1, -00095 XY_PLANE = 1 << 2, -00096 ZX_PLANE = 1 << 3, -00097 -00098 OPPOSITE_WINDING = 1 << 4 -00099 }; -00100 -00104 NV_FORCE_INLINE ProjectionDirections getProjectionDirection(const physx::PxVec3& normal) -00105 { -00106 float maxv = std::max(std::abs(normal.x), std::max(std::abs(normal.y), std::abs(normal.z))); -00107 ProjectionDirections retVal; -00108 if (maxv == std::abs(normal.x)) -00109 { -00110 retVal = YZ_PLANE; -00111 if (normal.x < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING); -00112 return retVal; -00113 } -00114 if (maxv == std::abs(normal.y)) -00115 { -00116 retVal = ZX_PLANE; -00117 if (normal.y > 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING); -00118 return retVal; -00119 } -00120 retVal = XY_PLANE; -00121 if (normal.z < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING); -00122 return retVal; -00123 } -00124 +00056 +00060 struct EdgeComparator +00061 { +00062 bool operator()(const EdgeWithParent& a, const EdgeWithParent& b) const +00063 { +00064 if (a.parent == b.parent) +00065 { +00066 if (a.s == b.s) +00067 { +00068 return a.e < b.e; +00069 } +00070 else +00071 { +00072 return a.s < b.s; +00073 } +00074 } +00075 else +00076 { +00077 return a.parent < b.parent; +00078 } +00079 } +00080 }; +00081 +00082 inline bool operator<(const Edge& a, const Edge& b) +00083 { +00084 if (a.s == b.s) +00085 return a.e < b.e; +00086 else +00087 return a.s < b.s; +00088 } +00089 +00093 enum ProjectionDirections +00094 { +00095 YZ_PLANE = 1 << 1, +00096 XY_PLANE = 1 << 2, +00097 ZX_PLANE = 1 << 3, +00098 +00099 OPPOSITE_WINDING = 1 << 4 +00100 }; +00101 +00105 NV_FORCE_INLINE ProjectionDirections getProjectionDirection(const physx::PxVec3& normal) +00106 { +00107 float maxv = std::max(std::abs(normal.x), std::max(std::abs(normal.y), std::abs(normal.z))); +00108 ProjectionDirections retVal; +00109 if (maxv == std::abs(normal.x)) +00110 { +00111 retVal = YZ_PLANE; +00112 if (normal.x < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING); +00113 return retVal; +00114 } +00115 if (maxv == std::abs(normal.y)) +00116 { +00117 retVal = ZX_PLANE; +00118 if (normal.y > 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING); +00119 return retVal; +00120 } +00121 retVal = XY_PLANE; +00122 if (normal.z < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING); +00123 return retVal; +00124 } 00125 -00129 NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const physx::PxVec3& point, ProjectionDirections dir) -00130 { -00131 if (dir & YZ_PLANE) -00132 { -00133 return physx::PxVec2(point.y, point.z); -00134 } -00135 if (dir & ZX_PLANE) -00136 { -00137 return physx::PxVec2(point.x, point.z); -00138 } -00139 return physx::PxVec2(point.x, point.y); -00140 } -00141 -00142 NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const NvcVec3& point, ProjectionDirections dir) -00143 { -00144 return getProjectedPoint((const physx::PxVec3&)point, dir); -00145 } -00146 -00150 NV_FORCE_INLINE physx::PxVec2 getProjectedPointWithWinding(const physx::PxVec3& point, ProjectionDirections dir) -00151 { -00152 if (dir & YZ_PLANE) -00153 { -00154 if (dir & OPPOSITE_WINDING) -00155 { -00156 return physx::PxVec2(point.z, point.y); -00157 } -00158 else -00159 return physx::PxVec2(point.y, point.z); -00160 } -00161 if (dir & ZX_PLANE) -00162 { -00163 if (dir & OPPOSITE_WINDING) -00164 { -00165 return physx::PxVec2(point.z, point.x); -00166 } -00167 return physx::PxVec2(point.x, point.z); -00168 } -00169 if (dir & OPPOSITE_WINDING) -00170 { -00171 return physx::PxVec2(point.y, point.x); -00172 } -00173 return physx::PxVec2(point.x, point.y); -00174 } -00175 +00126 +00130 NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const physx::PxVec3& point, ProjectionDirections dir) +00131 { +00132 if (dir & YZ_PLANE) +00133 { +00134 return physx::PxVec2(point.y, point.z); +00135 } +00136 if (dir & ZX_PLANE) +00137 { +00138 return physx::PxVec2(point.x, point.z); +00139 } +00140 return physx::PxVec2(point.x, point.y); +00141 } +00142 +00143 NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const NvcVec3& point, ProjectionDirections dir) +00144 { +00145 return getProjectedPoint((const physx::PxVec3&)point, dir); +00146 } +00147 +00151 NV_FORCE_INLINE physx::PxVec2 getProjectedPointWithWinding(const physx::PxVec3& point, ProjectionDirections dir) +00152 { +00153 if (dir & YZ_PLANE) +00154 { +00155 if (dir & OPPOSITE_WINDING) +00156 { +00157 return physx::PxVec2(point.z, point.y); +00158 } +00159 else +00160 return physx::PxVec2(point.y, point.z); +00161 } +00162 if (dir & ZX_PLANE) +00163 { +00164 if (dir & OPPOSITE_WINDING) +00165 { +00166 return physx::PxVec2(point.z, point.x); +00167 } +00168 return physx::PxVec2(point.x, point.z); +00169 } +00170 if (dir & OPPOSITE_WINDING) +00171 { +00172 return physx::PxVec2(point.y, point.x); +00173 } +00174 return physx::PxVec2(point.x, point.y); +00175 } 00176 00177 -00178 #define MAXIMUM_EXTENT 1000 * 1000 * 1000 -00179 #define BBOX_TEST_EPS 1e-5f -00180 -00184 NV_INLINE bool weakBoundingBoxIntersection(const physx::PxBounds3& aBox, const physx::PxBounds3& bBox) -00185 { -00186 if (std::max(aBox.minimum.x, bBox.minimum.x) > std::min(aBox.maximum.x, bBox.maximum.x) + BBOX_TEST_EPS) -00187 return false; -00188 if (std::max(aBox.minimum.y, bBox.minimum.y) > std::min(aBox.maximum.y, bBox.maximum.y) + BBOX_TEST_EPS) -00189 return false; -00190 if (std::max(aBox.minimum.z, bBox.minimum.z) > std::min(aBox.maximum.z, bBox.maximum.z) + BBOX_TEST_EPS) -00191 return false; -00192 return true; -00193 } -00194 +00178 +00179 #define MAXIMUM_EXTENT 1000 * 1000 * 1000 +00180 #define BBOX_TEST_EPS 1e-5f +00181 +00185 NV_INLINE bool weakBoundingBoxIntersection(const physx::PxBounds3& aBox, const physx::PxBounds3& bBox) +00186 { +00187 if (std::max(aBox.minimum.x, bBox.minimum.x) > std::min(aBox.maximum.x, bBox.maximum.x) + BBOX_TEST_EPS) +00188 return false; +00189 if (std::max(aBox.minimum.y, bBox.minimum.y) > std::min(aBox.maximum.y, bBox.maximum.y) + BBOX_TEST_EPS) +00190 return false; +00191 if (std::max(aBox.minimum.z, bBox.minimum.z) > std::min(aBox.maximum.z, bBox.maximum.z) + BBOX_TEST_EPS) +00192 return false; +00193 return true; +00194 } 00195 00196 -00200 NV_INLINE bool getPlaneSegmentIntersection(const physx::PxPlane& pl, const physx::PxVec3& a, const physx::PxVec3& b, -00201 physx::PxVec3& result) -00202 { -00203 float div = (b - a).dot(pl.n); -00204 if (physx::PxAbs(div) < 0.0001f) -00205 { -00206 if (pl.contains(a)) -00207 { -00208 result = a; -00209 return true; -00210 } -00211 else -00212 { -00213 return false; -00214 } -00215 } -00216 float t = (-a.dot(pl.n) - pl.d) / div; -00217 if (t < 0.0f || t > 1.0f) -00218 { -00219 return false; -00220 } -00221 result = (b - a) * t + a; -00222 return true; -00223 } -00224 +00197 +00201 NV_INLINE bool getPlaneSegmentIntersection(const physx::PxPlane& pl, const physx::PxVec3& a, const physx::PxVec3& b, +00202 physx::PxVec3& result) +00203 { +00204 float div = (b - a).dot(pl.n); +00205 if (physx::PxAbs(div) < 0.0001f) +00206 { +00207 if (pl.contains(a)) +00208 { +00209 result = a; +00210 return true; +00211 } +00212 else +00213 { +00214 return false; +00215 } +00216 } +00217 float t = (-a.dot(pl.n) - pl.d) / div; +00218 if (t < 0.0f || t > 1.0f) +00219 { +00220 return false; +00221 } +00222 result = (b - a) * t + a; +00223 return true; +00224 } 00225 -00226 #define POS_COMPARISON_OFFSET 1e-5f -00227 #define NORM_COMPARISON_OFFSET 1e-3f -00228 -00231 struct VrtComp -00232 { -00233 bool operator()(const Vertex& a, const Vertex& b) const -00234 { -00235 if (a.p.x + POS_COMPARISON_OFFSET < b.p.x) return true; -00236 if (a.p.x - POS_COMPARISON_OFFSET > b.p.x) return false; -00237 if (a.p.y + POS_COMPARISON_OFFSET < b.p.y) return true; -00238 if (a.p.y - POS_COMPARISON_OFFSET > b.p.y) return false; -00239 if (a.p.z + POS_COMPARISON_OFFSET < b.p.z) return true; -00240 if (a.p.z - POS_COMPARISON_OFFSET > b.p.z) return false; -00241 -00242 if (a.n.x + NORM_COMPARISON_OFFSET < b.n.x) return true; -00243 if (a.n.x - NORM_COMPARISON_OFFSET > b.n.x) return false; -00244 if (a.n.y + NORM_COMPARISON_OFFSET < b.n.y) return true; -00245 if (a.n.y - NORM_COMPARISON_OFFSET > b.n.y) return false; -00246 if (a.n.z + NORM_COMPARISON_OFFSET < b.n.z) return true; -00247 if (a.n.z - NORM_COMPARISON_OFFSET > b.n.z) return false; -00248 +00226 +00227 #define POS_COMPARISON_OFFSET 1e-5f +00228 #define NORM_COMPARISON_OFFSET 1e-3f +00229 +00232 struct VrtComp +00233 { +00234 bool operator()(const Vertex& a, const Vertex& b) const +00235 { +00236 if (a.p.x + POS_COMPARISON_OFFSET < b.p.x) return true; +00237 if (a.p.x - POS_COMPARISON_OFFSET > b.p.x) return false; +00238 if (a.p.y + POS_COMPARISON_OFFSET < b.p.y) return true; +00239 if (a.p.y - POS_COMPARISON_OFFSET > b.p.y) return false; +00240 if (a.p.z + POS_COMPARISON_OFFSET < b.p.z) return true; +00241 if (a.p.z - POS_COMPARISON_OFFSET > b.p.z) return false; +00242 +00243 if (a.n.x + NORM_COMPARISON_OFFSET < b.n.x) return true; +00244 if (a.n.x - NORM_COMPARISON_OFFSET > b.n.x) return false; +00245 if (a.n.y + NORM_COMPARISON_OFFSET < b.n.y) return true; +00246 if (a.n.y - NORM_COMPARISON_OFFSET > b.n.y) return false; +00247 if (a.n.z + NORM_COMPARISON_OFFSET < b.n.z) return true; +00248 if (a.n.z - NORM_COMPARISON_OFFSET > b.n.z) return false; 00249 -00250 if (a.uv[0].x + NORM_COMPARISON_OFFSET < b.uv[0].x) return true; -00251 if (a.uv[0].x - NORM_COMPARISON_OFFSET > b.uv[0].x) return false; -00252 if (a.uv[0].y + NORM_COMPARISON_OFFSET < b.uv[0].y) return true; -00253 return false; -00254 }; -00255 }; -00256 -00260 struct VrtPositionComparator -00261 { -00262 bool operator()(const NvcVec3& a, const NvcVec3& b) const -00263 { -00264 if (a.x + POS_COMPARISON_OFFSET < b.x) return true; -00265 if (a.x - POS_COMPARISON_OFFSET > b.x) return false; -00266 if (a.y + POS_COMPARISON_OFFSET < b.y) return true; -00267 if (a.y - POS_COMPARISON_OFFSET > b.y) return false; -00268 if (a.z + POS_COMPARISON_OFFSET < b.z) return true; -00269 if (a.z - POS_COMPARISON_OFFSET > b.z) return false; -00270 return false; -00271 }; -00272 bool operator()(const Vertex& a, const Vertex& b) const -00273 { -00274 return operator()(a.p, b.p); -00275 }; -00276 }; -00277 -00278 } // namespace Blast -00279 } // namespace Nv -00280 -00281 #endif +00250 +00251 if (a.uv[0].x + NORM_COMPARISON_OFFSET < b.uv[0].x) return true; +00252 if (a.uv[0].x - NORM_COMPARISON_OFFSET > b.uv[0].x) return false; +00253 if (a.uv[0].y + NORM_COMPARISON_OFFSET < b.uv[0].y) return true; +00254 return false; +00255 }; +00256 }; +00257 +00261 struct VrtPositionComparator +00262 { +00263 bool operator()(const NvcVec3& a, const NvcVec3& b) const +00264 { +00265 if (a.x + POS_COMPARISON_OFFSET < b.x) return true; +00266 if (a.x - POS_COMPARISON_OFFSET > b.x) return false; +00267 if (a.y + POS_COMPARISON_OFFSET < b.y) return true; +00268 if (a.y - POS_COMPARISON_OFFSET > b.y) return false; +00269 if (a.z + POS_COMPARISON_OFFSET < b.z) return true; +00270 if (a.z - POS_COMPARISON_OFFSET > b.z) return false; +00271 return false; +00272 }; +00273 bool operator()(const Vertex& a, const Vertex& b) const +00274 { +00275 return operator()(a.p, b.p); +00276 }; +00277 }; +00278 +00279 +00280 NV_INLINE float calculateCollisionHullVolume(const CollisionHull& hull) +00281 { +00282 if (hull.pointsCount == 0) +00283 { +00284 return 0.0f; +00285 } +00286 +00287 // Find an approximate centroid for a more accurate calculation +00288 NvcVec3 centroid = { 0.0f, 0.0f, 0.0f }; +00289 for (uint32_t i = 0; i < hull.pointsCount; ++i) +00290 { +00291 centroid = centroid + hull.points[i]; +00292 } +00293 centroid = centroid / hull.pointsCount; +00294 +00295 float volume = 0.0f; +00296 +00297 for (uint32_t i = 0; i < hull.polygonDataCount; ++i) +00298 { +00299 const HullPolygon& poly = hull.polygonData[i]; +00300 if (poly.vertexCount < 3) +00301 { +00302 continue; +00303 } +00304 const uint32_t i0 = hull.indices[poly.indexBase]; +00305 uint32_t i1 = hull.indices[poly.indexBase + 1]; +00306 for (uint32_t j = 2; j < poly.vertexCount; ++j) +00307 { +00308 const uint32_t i2 = hull.indices[poly.indexBase + j]; +00309 const NvcVec3 a = hull.points[i0] - centroid; +00310 const NvcVec3 b = hull.points[i1] - centroid; +00311 const NvcVec3 c = hull.points[i2] - centroid; +00312 volume += +00313 (a.x * b.y * c.z - a.x * b.z * c.y - a.y * b.x * c.z + a.y * b.z * c.x + a.z * b.x * c.y - a.z * b.y * c.x); +00314 i1 = i2; +00315 } +00316 } +00317 return (1.0f / 6.0f) * std::abs(volume); +00318 } +00319 +00320 } // namespace Blast +00321 } // namespace Nv +00322 +00323 #endif

sdk/extensions/authoringCommon/source/NvBlastExtAuthoringInternalCommon.h File Reference

#include "NvBlastExtAuthoringTypes.h"
+#include "NvBlastPxSharedHelpers.h"
#include <PxVec2.h>
#include <PxVec3.h>
#include <PxPlane.h>
@@ -80,6 +81,8 @@ }

Functions

+NV_INLINE float Nv::Blast::calculateCollisionHullVolume (const CollisionHull &hull) + NV_INLINE bool Nv::Blast::getPlaneSegmentIntersection (const physx::PxPlane &pl, const physx::PxVec3 &a, const physx::PxVec3 &b, physx::PxVec3 &result) NV_FORCE_INLINE physx::PxVec2 Nv::Blast::getProjectedPoint (const NvcVec3 &point, ProjectionDirections dir) diff --git a/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h.js b/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h.js index 6af0abf..868c752 100755 --- a/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h.js +++ b/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h.js @@ -14,6 +14,7 @@ var _nv_blast_ext_authoring_internal_common_8h = [ "ZX_PLANE", "_nv_blast_ext_authoring_internal_common_8h.html#a2dbf0cc037620db35223513e817444f7a34e384d7641d38d0e6f9e601f5d868ac", null ], [ "OPPOSITE_WINDING", "_nv_blast_ext_authoring_internal_common_8h.html#a2dbf0cc037620db35223513e817444f7af9063b45980bcdd587cd7b7be4444152", null ] ] ], + [ "calculateCollisionHullVolume", "_nv_blast_ext_authoring_internal_common_8h.html#ad7f758469903c6a753a827ee1525a1e8", null ], [ "getPlaneSegmentIntersection", "_nv_blast_ext_authoring_internal_common_8h.html#a7bba8d1f555e341010029032391276a6", null ], [ "getProjectedPoint", "_nv_blast_ext_authoring_internal_common_8h.html#a44d0b01b83d001724a34646ec96d17f0", null ], [ "getProjectedPoint", "_nv_blast_ext_authoring_internal_common_8h.html#a07798b57f728802d367a7efbea3ce3a7", null ], diff --git a/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h_source.html b/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h_source.html index 7e83869..d78bd76 100755 --- a/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h_source.html +++ b/docs/source_docs/files/_nv_blast_ext_authoring_internal_common_8h_source.html @@ -46,53 +46,64 @@ $(document).ready(function(){initNavTree('_nv_blast_ext_authoring_internal_commo
NvBlastExtAuthoringInternalCommon.h
-Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTINTERNALCOMMON_H
30 #define NVBLASTINTERNALCOMMON_H
32 #include <PxVec2.h>
33 #include <PxVec3.h>
34 #include <PxPlane.h>
35 #include <PxBounds3.h>
36 #include <PxMath.h>
37 #include <algorithm>
38 
39 namespace Nv
40 {
41 namespace Blast
42 {
43 
48 {
49  uint32_t s, e; // Starting and ending vertices
50  uint32_t parent; // Parent facet index
51  EdgeWithParent() : s(0), e(0), parent(0) {}
52  EdgeWithParent(uint32_t s, uint32_t e, uint32_t p) : s(s), e(e), parent(p) {}
53 };
54 
55 
60 {
61  bool operator()(const EdgeWithParent& a, const EdgeWithParent& b) const
62  {
63  if (a.parent == b.parent)
64  {
65  if (a.s == b.s)
66  {
67  return a.e < b.e;
68  }
69  else
70  {
71  return a.s < b.s;
72  }
73  }
74  else
75  {
76  return a.parent < b.parent;
77  }
78  }
79 };
80 
81 inline bool operator<(const Edge& a, const Edge& b)
82 {
83  if (a.s == b.s)
84  return a.e < b.e;
85  else
86  return a.s < b.s;
87 }
88 
93 {
94  YZ_PLANE = 1 << 1,
95  XY_PLANE = 1 << 2,
96  ZX_PLANE = 1 << 3,
97 
99 };
100 
105 {
106  float maxv = std::max(std::abs(normal.x), std::max(std::abs(normal.y), std::abs(normal.z)));
107  ProjectionDirections retVal;
108  if (maxv == std::abs(normal.x))
109  {
110  retVal = YZ_PLANE;
111  if (normal.x < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING);
112  return retVal;
113  }
114  if (maxv == std::abs(normal.y))
115  {
116  retVal = ZX_PLANE;
117  if (normal.y > 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING);
118  return retVal;
119  }
120  retVal = XY_PLANE;
121  if (normal.z < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING);
122  return retVal;
123 }
124 
125 
129 NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const physx::PxVec3& point, ProjectionDirections dir)
130 {
131  if (dir & YZ_PLANE)
132  {
133  return physx::PxVec2(point.y, point.z);
134  }
135  if (dir & ZX_PLANE)
136  {
137  return physx::PxVec2(point.x, point.z);
138  }
139  return physx::PxVec2(point.x, point.y);
140 }
141 
143 {
144  return getProjectedPoint((const physx::PxVec3&)point, dir);
145 }
146 
150 NV_FORCE_INLINE physx::PxVec2 getProjectedPointWithWinding(const physx::PxVec3& point, ProjectionDirections dir)
151 {
152  if (dir & YZ_PLANE)
153  {
154  if (dir & OPPOSITE_WINDING)
155  {
156  return physx::PxVec2(point.z, point.y);
157  }
158  else
159  return physx::PxVec2(point.y, point.z);
160  }
161  if (dir & ZX_PLANE)
162  {
163  if (dir & OPPOSITE_WINDING)
164  {
165  return physx::PxVec2(point.z, point.x);
166  }
167  return physx::PxVec2(point.x, point.z);
168  }
169  if (dir & OPPOSITE_WINDING)
170  {
171  return physx::PxVec2(point.y, point.x);
172  }
173  return physx::PxVec2(point.x, point.y);
174 }
175 
176 
177 
178 #define MAXIMUM_EXTENT 1000 * 1000 * 1000
179 #define BBOX_TEST_EPS 1e-5f
180 
184 NV_INLINE bool weakBoundingBoxIntersection(const physx::PxBounds3& aBox, const physx::PxBounds3& bBox)
185 {
186  if (std::max(aBox.minimum.x, bBox.minimum.x) > std::min(aBox.maximum.x, bBox.maximum.x) + BBOX_TEST_EPS)
187  return false;
188  if (std::max(aBox.minimum.y, bBox.minimum.y) > std::min(aBox.maximum.y, bBox.maximum.y) + BBOX_TEST_EPS)
189  return false;
190  if (std::max(aBox.minimum.z, bBox.minimum.z) > std::min(aBox.maximum.z, bBox.maximum.z) + BBOX_TEST_EPS)
191  return false;
192  return true;
193 }
194 
195 
196 
200 NV_INLINE bool getPlaneSegmentIntersection(const physx::PxPlane& pl, const physx::PxVec3& a, const physx::PxVec3& b,
201  physx::PxVec3& result)
202 {
203  float div = (b - a).dot(pl.n);
204  if (physx::PxAbs(div) < 0.0001f)
205  {
206  if (pl.contains(a))
207  {
208  result = a;
209  return true;
210  }
211  else
212  {
213  return false;
214  }
215  }
216  float t = (-a.dot(pl.n) - pl.d) / div;
217  if (t < 0.0f || t > 1.0f)
218  {
219  return false;
220  }
221  result = (b - a) * t + a;
222  return true;
223 }
224 
225 
226 #define POS_COMPARISON_OFFSET 1e-5f
227 #define NORM_COMPARISON_OFFSET 1e-3f
228 
231 struct VrtComp
232 {
233  bool operator()(const Vertex& a, const Vertex& b) const
234  {
235  if (a.p.x + POS_COMPARISON_OFFSET < b.p.x) return true;
236  if (a.p.x - POS_COMPARISON_OFFSET > b.p.x) return false;
237  if (a.p.y + POS_COMPARISON_OFFSET < b.p.y) return true;
238  if (a.p.y - POS_COMPARISON_OFFSET > b.p.y) return false;
239  if (a.p.z + POS_COMPARISON_OFFSET < b.p.z) return true;
240  if (a.p.z - POS_COMPARISON_OFFSET > b.p.z) return false;
241 
242  if (a.n.x + NORM_COMPARISON_OFFSET < b.n.x) return true;
243  if (a.n.x - NORM_COMPARISON_OFFSET > b.n.x) return false;
244  if (a.n.y + NORM_COMPARISON_OFFSET < b.n.y) return true;
245  if (a.n.y - NORM_COMPARISON_OFFSET > b.n.y) return false;
246  if (a.n.z + NORM_COMPARISON_OFFSET < b.n.z) return true;
247  if (a.n.z - NORM_COMPARISON_OFFSET > b.n.z) return false;
248 
249 
250  if (a.uv[0].x + NORM_COMPARISON_OFFSET < b.uv[0].x) return true;
251  if (a.uv[0].x - NORM_COMPARISON_OFFSET > b.uv[0].x) return false;
252  if (a.uv[0].y + NORM_COMPARISON_OFFSET < b.uv[0].y) return true;
253  return false;
254  };
255 };
256 
261 {
262  bool operator()(const NvcVec3& a, const NvcVec3& b) const
263  {
264  if (a.x + POS_COMPARISON_OFFSET < b.x) return true;
265  if (a.x - POS_COMPARISON_OFFSET > b.x) return false;
266  if (a.y + POS_COMPARISON_OFFSET < b.y) return true;
267  if (a.y - POS_COMPARISON_OFFSET > b.y) return false;
268  if (a.z + POS_COMPARISON_OFFSET < b.z) return true;
269  if (a.z - POS_COMPARISON_OFFSET > b.z) return false;
270  return false;
271  };
272  bool operator()(const Vertex& a, const Vertex& b) const
273  {
274  return operator()(a.p, b.p);
275  };
276 };
277 
278 } // namespace Blast
279 } // namespace Nv
280 
281 #endif
bool operator()(const Vertex &a, const Vertex &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:272
-
ProjectionDirections
Definition: NvBlastExtAuthoringInternalCommon.h:92
+Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTINTERNALCOMMON_H
30 #define NVBLASTINTERNALCOMMON_H
32 #include "NvBlastPxSharedHelpers.h"
33 #include <PxVec2.h>
34 #include <PxVec3.h>
35 #include <PxPlane.h>
36 #include <PxBounds3.h>
37 #include <PxMath.h>
38 #include <algorithm>
39 
40 namespace Nv
41 {
42 namespace Blast
43 {
44 
49 {
50  uint32_t s, e; // Starting and ending vertices
51  uint32_t parent; // Parent facet index
52  EdgeWithParent() : s(0), e(0), parent(0) {}
53  EdgeWithParent(uint32_t s, uint32_t e, uint32_t p) : s(s), e(e), parent(p) {}
54 };
55 
56 
61 {
62  bool operator()(const EdgeWithParent& a, const EdgeWithParent& b) const
63  {
64  if (a.parent == b.parent)
65  {
66  if (a.s == b.s)
67  {
68  return a.e < b.e;
69  }
70  else
71  {
72  return a.s < b.s;
73  }
74  }
75  else
76  {
77  return a.parent < b.parent;
78  }
79  }
80 };
81 
82 inline bool operator<(const Edge& a, const Edge& b)
83 {
84  if (a.s == b.s)
85  return a.e < b.e;
86  else
87  return a.s < b.s;
88 }
89 
94 {
95  YZ_PLANE = 1 << 1,
96  XY_PLANE = 1 << 2,
97  ZX_PLANE = 1 << 3,
98 
100 };
101 
106 {
107  float maxv = std::max(std::abs(normal.x), std::max(std::abs(normal.y), std::abs(normal.z)));
108  ProjectionDirections retVal;
109  if (maxv == std::abs(normal.x))
110  {
111  retVal = YZ_PLANE;
112  if (normal.x < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING);
113  return retVal;
114  }
115  if (maxv == std::abs(normal.y))
116  {
117  retVal = ZX_PLANE;
118  if (normal.y > 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING);
119  return retVal;
120  }
121  retVal = XY_PLANE;
122  if (normal.z < 0) retVal = (ProjectionDirections)((int)retVal | (int)OPPOSITE_WINDING);
123  return retVal;
124 }
125 
126 
130 NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const physx::PxVec3& point, ProjectionDirections dir)
131 {
132  if (dir & YZ_PLANE)
133  {
134  return physx::PxVec2(point.y, point.z);
135  }
136  if (dir & ZX_PLANE)
137  {
138  return physx::PxVec2(point.x, point.z);
139  }
140  return physx::PxVec2(point.x, point.y);
141 }
142 
144 {
145  return getProjectedPoint((const physx::PxVec3&)point, dir);
146 }
147 
151 NV_FORCE_INLINE physx::PxVec2 getProjectedPointWithWinding(const physx::PxVec3& point, ProjectionDirections dir)
152 {
153  if (dir & YZ_PLANE)
154  {
155  if (dir & OPPOSITE_WINDING)
156  {
157  return physx::PxVec2(point.z, point.y);
158  }
159  else
160  return physx::PxVec2(point.y, point.z);
161  }
162  if (dir & ZX_PLANE)
163  {
164  if (dir & OPPOSITE_WINDING)
165  {
166  return physx::PxVec2(point.z, point.x);
167  }
168  return physx::PxVec2(point.x, point.z);
169  }
170  if (dir & OPPOSITE_WINDING)
171  {
172  return physx::PxVec2(point.y, point.x);
173  }
174  return physx::PxVec2(point.x, point.y);
175 }
176 
177 
178 
179 #define MAXIMUM_EXTENT 1000 * 1000 * 1000
180 #define BBOX_TEST_EPS 1e-5f
181 
185 NV_INLINE bool weakBoundingBoxIntersection(const physx::PxBounds3& aBox, const physx::PxBounds3& bBox)
186 {
187  if (std::max(aBox.minimum.x, bBox.minimum.x) > std::min(aBox.maximum.x, bBox.maximum.x) + BBOX_TEST_EPS)
188  return false;
189  if (std::max(aBox.minimum.y, bBox.minimum.y) > std::min(aBox.maximum.y, bBox.maximum.y) + BBOX_TEST_EPS)
190  return false;
191  if (std::max(aBox.minimum.z, bBox.minimum.z) > std::min(aBox.maximum.z, bBox.maximum.z) + BBOX_TEST_EPS)
192  return false;
193  return true;
194 }
195 
196 
197 
201 NV_INLINE bool getPlaneSegmentIntersection(const physx::PxPlane& pl, const physx::PxVec3& a, const physx::PxVec3& b,
202  physx::PxVec3& result)
203 {
204  float div = (b - a).dot(pl.n);
205  if (physx::PxAbs(div) < 0.0001f)
206  {
207  if (pl.contains(a))
208  {
209  result = a;
210  return true;
211  }
212  else
213  {
214  return false;
215  }
216  }
217  float t = (-a.dot(pl.n) - pl.d) / div;
218  if (t < 0.0f || t > 1.0f)
219  {
220  return false;
221  }
222  result = (b - a) * t + a;
223  return true;
224 }
225 
226 
227 #define POS_COMPARISON_OFFSET 1e-5f
228 #define NORM_COMPARISON_OFFSET 1e-3f
229 
232 struct VrtComp
233 {
234  bool operator()(const Vertex& a, const Vertex& b) const
235  {
236  if (a.p.x + POS_COMPARISON_OFFSET < b.p.x) return true;
237  if (a.p.x - POS_COMPARISON_OFFSET > b.p.x) return false;
238  if (a.p.y + POS_COMPARISON_OFFSET < b.p.y) return true;
239  if (a.p.y - POS_COMPARISON_OFFSET > b.p.y) return false;
240  if (a.p.z + POS_COMPARISON_OFFSET < b.p.z) return true;
241  if (a.p.z - POS_COMPARISON_OFFSET > b.p.z) return false;
242 
243  if (a.n.x + NORM_COMPARISON_OFFSET < b.n.x) return true;
244  if (a.n.x - NORM_COMPARISON_OFFSET > b.n.x) return false;
245  if (a.n.y + NORM_COMPARISON_OFFSET < b.n.y) return true;
246  if (a.n.y - NORM_COMPARISON_OFFSET > b.n.y) return false;
247  if (a.n.z + NORM_COMPARISON_OFFSET < b.n.z) return true;
248  if (a.n.z - NORM_COMPARISON_OFFSET > b.n.z) return false;
249 
250 
251  if (a.uv[0].x + NORM_COMPARISON_OFFSET < b.uv[0].x) return true;
252  if (a.uv[0].x - NORM_COMPARISON_OFFSET > b.uv[0].x) return false;
253  if (a.uv[0].y + NORM_COMPARISON_OFFSET < b.uv[0].y) return true;
254  return false;
255  };
256 };
257 
262 {
263  bool operator()(const NvcVec3& a, const NvcVec3& b) const
264  {
265  if (a.x + POS_COMPARISON_OFFSET < b.x) return true;
266  if (a.x - POS_COMPARISON_OFFSET > b.x) return false;
267  if (a.y + POS_COMPARISON_OFFSET < b.y) return true;
268  if (a.y - POS_COMPARISON_OFFSET > b.y) return false;
269  if (a.z + POS_COMPARISON_OFFSET < b.z) return true;
270  if (a.z - POS_COMPARISON_OFFSET > b.z) return false;
271  return false;
272  };
273  bool operator()(const Vertex& a, const Vertex& b) const
274  {
275  return operator()(a.p, b.p);
276  };
277 };
278 
279 
281 {
282  if (hull.pointsCount == 0)
283  {
284  return 0.0f;
285  }
286 
287  // Find an approximate centroid for a more accurate calculation
288  NvcVec3 centroid = { 0.0f, 0.0f, 0.0f };
289  for (uint32_t i = 0; i < hull.pointsCount; ++i)
290  {
291  centroid = centroid + hull.points[i];
292  }
293  centroid = centroid / hull.pointsCount;
294 
295  float volume = 0.0f;
296 
297  for (uint32_t i = 0; i < hull.polygonDataCount; ++i)
298  {
299  const HullPolygon& poly = hull.polygonData[i];
300  if (poly.vertexCount < 3)
301  {
302  continue;
303  }
304  const uint32_t i0 = hull.indices[poly.indexBase];
305  uint32_t i1 = hull.indices[poly.indexBase + 1];
306  for (uint32_t j = 2; j < poly.vertexCount; ++j)
307  {
308  const uint32_t i2 = hull.indices[poly.indexBase + j];
309  const NvcVec3 a = hull.points[i0] - centroid;
310  const NvcVec3 b = hull.points[i1] - centroid;
311  const NvcVec3 c = hull.points[i2] - centroid;
312  volume +=
313  (a.x * b.y * c.z - a.x * b.z * c.y - a.y * b.x * c.z + a.y * b.z * c.x + a.z * b.x * c.y - a.z * b.y * c.x);
314  i1 = i2;
315  }
316  }
317  return (1.0f / 6.0f) * std::abs(volume);
318 }
319 
320 } // namespace Blast
321 } // namespace Nv
322 
323 #endif
bool operator()(const Vertex &a, const Vertex &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:273
+
ProjectionDirections
Definition: NvBlastExtAuthoringInternalCommon.h:93
uint32_t e
Definition: NvBlastExtAuthoringTypes.h:61
-
uint32_t s
Definition: NvBlastExtAuthoringInternalCommon.h:49
-
Definition: NvBlastExtAuthoringInternalCommon.h:94
-
Definition: NvBlastExtAuthoringInternalCommon.h:95
-
#define NORM_COMPARISON_OFFSET
Definition: NvBlastExtAuthoringInternalCommon.h:227
+
uint32_t s
Definition: NvBlastExtAuthoringInternalCommon.h:50
+
uint16_t indexBase
Definition: NvBlastExtAuthoringTypes.h:127
+
Definition: NvBlastExtAuthoringInternalCommon.h:95
+
Definition: NvBlastExtAuthoringInternalCommon.h:96
+
#define NORM_COMPARISON_OFFSET
Definition: NvBlastExtAuthoringInternalCommon.h:228
NV_INLINE float normal(const float a[3], float r[3])
Definition: NvBlastMath.h:93
-
Definition: NvBlastExtAuthoringInternalCommon.h:47
+
Definition: NvBlastExtAuthoringInternalCommon.h:48
float z
Definition: NvCTypes.h:51
-
Definition: NvBlastExtAuthoringInternalCommon.h:59
+
Definition: NvBlastExtAuthoringInternalCommon.h:60
+
uint16_t vertexCount
Definition: NvBlastExtAuthoringTypes.h:125
NvcVec3 n
Definition: NvBlastExtAuthoringTypes.h:72
-
#define BBOX_TEST_EPS
Definition: NvBlastExtAuthoringInternalCommon.h:179
-
bool operator<(const Edge &a, const Edge &b)
Definition: NvBlastExtAuthoringInternalCommon.h:81
-
uint32_t e
Definition: NvBlastExtAuthoringInternalCommon.h:49
+
uint32_t * indices
Definition: NvBlastExtAuthoringTypes.h:139
+
#define BBOX_TEST_EPS
Definition: NvBlastExtAuthoringInternalCommon.h:180
+
bool operator<(const Edge &a, const Edge &b)
Definition: NvBlastExtAuthoringInternalCommon.h:82
+
NV_INLINE float calculateCollisionHullVolume(const CollisionHull &hull)
Definition: NvBlastExtAuthoringInternalCommon.h:280
+
uint32_t e
Definition: NvBlastExtAuthoringInternalCommon.h:50
+
HullPolygon * polygonData
Definition: NvBlastExtAuthoringTypes.h:140
+
Definition: NvBlastExtAuthoringTypes.h:120
float x
Definition: NvCTypes.h:51
-
Definition: NvBlastExtAuthoringInternalCommon.h:98
+
Definition: NvBlastExtAuthoringInternalCommon.h:99
+
Definition: NvBlastExtAuthoringTypes.h:133
NV_INLINE void div(float a[3], float divisor)
Definition: NvBlastMath.h:43
float x
Definition: NvCTypes.h:45
-
bool operator()(const Vertex &a, const Vertex &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:233
-
Definition: NvBlastExtAuthoringInternalCommon.h:96
+
bool operator()(const Vertex &a, const Vertex &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:234
+
Definition: NvBlastExtAuthoringInternalCommon.h:97
#define NV_INLINE
Definition: NvPreprocessor.h:350
-
Definition: NvBlastExtAuthoringInternalCommon.h:231
+
Definition: NvBlastExtAuthoringInternalCommon.h:232
+
NvcVec3 * points
Definition: NvBlastExtAuthoringTypes.h:138
+
uint32_t pointsCount
Definition: NvBlastExtAuthoringTypes.h:135
NvcVec2 uv[1]
Definition: NvBlastExtAuthoringTypes.h:73
-
Definition: NvBlastExtAuthoringInternalCommon.h:260
-
NV_FORCE_INLINE physx::PxVec2 getProjectedPointWithWinding(const physx::PxVec3 &point, ProjectionDirections dir)
Definition: NvBlastExtAuthoringInternalCommon.h:150
-
uint32_t parent
Definition: NvBlastExtAuthoringInternalCommon.h:50
-
bool operator()(const NvcVec3 &a, const NvcVec3 &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:262
+
Definition: NvBlastExtAuthoringInternalCommon.h:261
+
NV_FORCE_INLINE physx::PxVec2 getProjectedPointWithWinding(const physx::PxVec3 &point, ProjectionDirections dir)
Definition: NvBlastExtAuthoringInternalCommon.h:151
+
uint32_t parent
Definition: NvBlastExtAuthoringInternalCommon.h:51
+
bool operator()(const NvcVec3 &a, const NvcVec3 &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:263
+
uint32_t polygonDataCount
Definition: NvBlastExtAuthoringTypes.h:137
NV_INLINE float dot(const float a[3], const float b[3])
Definition: NvBlastMath.h:73
-
EdgeWithParent(uint32_t s, uint32_t e, uint32_t p)
Definition: NvBlastExtAuthoringInternalCommon.h:52
-
NV_FORCE_INLINE ProjectionDirections getProjectionDirection(const physx::PxVec3 &normal)
Definition: NvBlastExtAuthoringInternalCommon.h:104
-
NV_INLINE bool weakBoundingBoxIntersection(const physx::PxBounds3 &aBox, const physx::PxBounds3 &bBox)
Definition: NvBlastExtAuthoringInternalCommon.h:184
-
#define POS_COMPARISON_OFFSET
Definition: NvBlastExtAuthoringInternalCommon.h:226
+
EdgeWithParent(uint32_t s, uint32_t e, uint32_t p)
Definition: NvBlastExtAuthoringInternalCommon.h:53
+
NV_FORCE_INLINE ProjectionDirections getProjectionDirection(const physx::PxVec3 &normal)
Definition: NvBlastExtAuthoringInternalCommon.h:105
+
NV_INLINE bool weakBoundingBoxIntersection(const physx::PxBounds3 &aBox, const physx::PxBounds3 &bBox)
Definition: NvBlastExtAuthoringInternalCommon.h:185
+
#define POS_COMPARISON_OFFSET
Definition: NvBlastExtAuthoringInternalCommon.h:227
Definition: NvBlastExtAuthoringTypes.h:57
-
NV_INLINE bool getPlaneSegmentIntersection(const physx::PxPlane &pl, const physx::PxVec3 &a, const physx::PxVec3 &b, physx::PxVec3 &result)
Definition: NvBlastExtAuthoringInternalCommon.h:200
+
NV_INLINE bool getPlaneSegmentIntersection(const physx::PxPlane &pl, const physx::PxVec3 &a, const physx::PxVec3 &b, physx::PxVec3 &result)
Definition: NvBlastExtAuthoringInternalCommon.h:201
Definition: NvBlastExtAuthoringTypes.h:67
NvcVec3 p
Definition: NvBlastExtAuthoringTypes.h:71
-
NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const physx::PxVec3 &point, ProjectionDirections dir)
Definition: NvBlastExtAuthoringInternalCommon.h:129
-
bool operator()(const EdgeWithParent &a, const EdgeWithParent &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:61
+
NV_FORCE_INLINE physx::PxVec2 getProjectedPoint(const physx::PxVec3 &point, ProjectionDirections dir)
Definition: NvBlastExtAuthoringInternalCommon.h:130
+
bool operator()(const EdgeWithParent &a, const EdgeWithParent &b) const
Definition: NvBlastExtAuthoringInternalCommon.h:62
+
float y
Definition: NvCTypes.h:45
Definition: NvBlastArray.h:37
Definition: NvCTypes.h:49
#define NV_FORCE_INLINE
Definition: NvPreprocessor.h:365
uint32_t s
Definition: NvBlastExtAuthoringTypes.h:60
float y
Definition: NvCTypes.h:51
-
EdgeWithParent()
Definition: NvBlastExtAuthoringInternalCommon.h:51
+
EdgeWithParent()
Definition: NvBlastExtAuthoringInternalCommon.h:52
diff --git a/docs/source_docs/files/_nv_blast_ext_authoring_triangulator_8h_source.html b/docs/source_docs/files/_nv_blast_ext_authoring_triangulator_8h_source.html index 2cde922..19783dc 100755 --- a/docs/source_docs/files/_nv_blast_ext_authoring_triangulator_8h_source.html +++ b/docs/source_docs/files/_nv_blast_ext_authoring_triangulator_8h_source.html @@ -46,10 +46,10 @@ $(document).ready(function(){initNavTree('_nv_blast_ext_authoring_triangulator_8
NvBlastExtAuthoringTriangulator.h
-Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTEXTAUTHORINGTRIANGULATOR_H
30 #define NVBLASTEXTAUTHORINGTRIANGULATOR_H
31 
32 
33 #include <vector>
34 #include <map>
38 
39 namespace Nv
40 {
41 namespace Blast
42 {
43 
44 
49 {
50 public:
55  void triangulate(const Mesh* mesh);
56 
60  std::vector<Triangle>& getBaseMesh()
61  {
62  return mBaseMeshUVFittedTriangles;
63  }
64 
65  std::vector<Triangle>& getBaseMeshNotFitted()
66  {
67  return mBaseMeshResultTriangles;
68  }
69 
70 
74  std::vector<TriangleIndexed>& getBaseMeshIndexed()
75  {
76  return mBaseMeshTriangles;
77  }
81  std::vector<uint32_t>& getBaseMapping()
82  {
83  return mBaseMapping;
84  };
88  std::vector<int32_t>& getPositionedMapping()
89  {
90  return mPositionMappedVrt;
91  };
96  {
97  return static_cast<uint32_t>(mVertices.size());
98  }
99 
103  void reset();
104 
105  int32_t& getParentChunkId() { return parentChunkId; };
106 
107 private:
108 
109  int32_t parentChunkId;
110 
111  int32_t addVerticeIfNotExist(const Vertex& p);
112  void addEdgeIfValid(EdgeWithParent& ed);
113 
114  /* Data used before triangulation to build polygon loops*/
115 
116  std::vector<Vertex> mVertices;
117  std::vector<EdgeWithParent> mBaseMeshEdges;
118  std::map<Vertex, int32_t, VrtComp> mVertMap;
119  std::map<EdgeWithParent, int32_t, EdgeComparator> mEdgeMap;
120  std::vector<uint32_t> mBaseMapping;
121  std::vector<int32_t> mPositionMappedVrt;
122  /* ------------------------------------------------------------ */
123 
124 
128  void prepare(const Mesh* mesh);
129 
130 
131 
132  void triangulatePolygonWithEarClipping(std::vector<uint32_t>& inputPolygon, Vertex* vert, ProjectionDirections dir);
133  void buildPolygonAndTriangulate(std::vector<Edge>& edges, Vertex* vertices, int32_t userData, int32_t materialId, int32_t smoothingGroup);
134  void computePositionedMapping();
135 
136  std::vector<TriangleIndexed> mBaseMeshTriangles;
140  std::vector<Triangle> mBaseMeshResultTriangles;
141  std::vector<Triangle> mBaseMeshUVFittedTriangles;
142 };
143 
144 } // namespace Blast
145 } // namespace Nv
146 
147 
148 #endif // ifndef NVBLASTEXTAUTHORINGTRIANGULATOR_H
ProjectionDirections
Definition: NvBlastExtAuthoringInternalCommon.h:92
+Go to the documentation of this file.
1 // This code contains NVIDIA Confidential Information and is disclosed to you
2 // under a form of NVIDIA software license agreement provided separately to you.
3 //
4 // Notice
5 // NVIDIA Corporation and its licensors retain all intellectual property and
6 // proprietary rights in and to this software and related documentation and
7 // any modifications thereto. Any use, reproduction, disclosure, or
8 // distribution of this software and related documentation without an express
9 // license agreement from NVIDIA Corporation is strictly prohibited.
10 //
11 // ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
12 // NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
13 // THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
14 // MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.
15 //
16 // Information and code furnished is believed to be accurate and reliable.
17 // However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
18 // information or for any infringement of patents or other rights of third parties that may
19 // result from its use. No license is granted by implication or otherwise under any patent
20 // or patent rights of NVIDIA Corporation. Details are subject to change without notice.
21 // This code supersedes and replaces all information previously supplied.
22 // NVIDIA Corporation products are not authorized for use as critical
23 // components in life support devices or systems without express written approval of
24 // NVIDIA Corporation.
25 //
26 // Copyright (c) 2016-2018 NVIDIA Corporation. All rights reserved.
27 
28 
29 #ifndef NVBLASTEXTAUTHORINGTRIANGULATOR_H
30 #define NVBLASTEXTAUTHORINGTRIANGULATOR_H
31 
32 
33 #include <vector>
34 #include <map>
38 
39 namespace Nv
40 {
41 namespace Blast
42 {
43 
44 
49 {
50 public:
55  void triangulate(const Mesh* mesh);
56 
60  std::vector<Triangle>& getBaseMesh()
61  {
62  return mBaseMeshUVFittedTriangles;
63  }
64 
65  std::vector<Triangle>& getBaseMeshNotFitted()
66  {
67  return mBaseMeshResultTriangles;
68  }
69 
70 
74  std::vector<TriangleIndexed>& getBaseMeshIndexed()
75  {
76  return mBaseMeshTriangles;
77  }
81  std::vector<uint32_t>& getBaseMapping()
82  {
83  return mBaseMapping;
84  };
88  std::vector<int32_t>& getPositionedMapping()
89  {
90  return mPositionMappedVrt;
91  };
96  {
97  return static_cast<uint32_t>(mVertices.size());
98  }
99 
103  void reset();
104 
105  int32_t& getParentChunkId() { return parentChunkId; };
106 
107 private:
108 
109  int32_t parentChunkId;
110 
111  int32_t addVerticeIfNotExist(const Vertex& p);
112  void addEdgeIfValid(EdgeWithParent& ed);
113 
114  /* Data used before triangulation to build polygon loops*/
115 
116  std::vector<Vertex> mVertices;
117  std::vector<EdgeWithParent> mBaseMeshEdges;
118  std::map<Vertex, int32_t, VrtComp> mVertMap;
119  std::map<EdgeWithParent, int32_t, EdgeComparator> mEdgeMap;
120  std::vector<uint32_t> mBaseMapping;
121  std::vector<int32_t> mPositionMappedVrt;
122  /* ------------------------------------------------------------ */
123 
124 
128  void prepare(const Mesh* mesh);
129 
130 
131 
132  void triangulatePolygonWithEarClipping(std::vector<uint32_t>& inputPolygon, Vertex* vert, ProjectionDirections dir);
133  void buildPolygonAndTriangulate(std::vector<Edge>& edges, Vertex* vertices, int32_t userData, int32_t materialId, int32_t smoothingGroup);
134  void computePositionedMapping();
135 
136  std::vector<TriangleIndexed> mBaseMeshTriangles;
140  std::vector<Triangle> mBaseMeshResultTriangles;
141  std::vector<Triangle> mBaseMeshUVFittedTriangles;
142 };
143 
144 } // namespace Blast
145 } // namespace Nv
146 
147 
148 #endif // ifndef NVBLASTEXTAUTHORINGTRIANGULATOR_H
ProjectionDirections
Definition: NvBlastExtAuthoringInternalCommon.h:93
std::vector< int32_t > & getPositionedMapping()
Definition: NvBlastExtAuthoringTriangulator.h:88
std::vector< Triangle > & getBaseMeshNotFitted()
Definition: NvBlastExtAuthoringTriangulator.h:65
-
Definition: NvBlastExtAuthoringInternalCommon.h:47
+
Definition: NvBlastExtAuthoringInternalCommon.h:48
std::vector< uint32_t > & getBaseMapping()
Definition: NvBlastExtAuthoringTriangulator.h:81
uint32_t getWeldedVerticesCount()
Definition: NvBlastExtAuthoringTriangulator.h:95
diff --git a/docs/source_docs/files/_nv_blast_ext_r_t_geometry_8h_source.html b/docs/source_docs/files/_nv_blast_ext_r_t_geometry_8h_source.html index dbb90b4..922e8d0 100644 --- a/docs/source_docs/files/_nv_blast_ext_r_t_geometry_8h_source.html +++ b/docs/source_docs/files/_nv_blast_ext_r_t_geometry_8h_source.html @@ -47,7 +47,7 @@ $(document).ready(function(){initNavTree('_nv_blast_ext_r_t_geometry_8h_source.h
Go to the documentation of this file.
1 #pragma once
5 #include "NvBlastExtRT.h"
6 #include <map>
7 
8 using physx::PxVec3;
9 using physx::PxVec2;
10 
11 
12 namespace Nv
13 {
14  namespace Blast
15  {
16  class Mesh;
17 
19  {
20  public:
21 
22  typedef int32_t (VertexWelding::*LOCATE_CALLBACK)(const Vertex& v, uint32_t bucket, bool& isAllDataTheSame);
23 
24  VertexWelding(uint32_t maxVertexCount, uint32_t maxBucketCount, float gridCellSize, float weldEpsilon, float auxEpsilon, LOCATE_CALLBACK clb);
25 
26  const Vertex* getVertices() const
27  {
28  return vertex.data();
29  }
30  uint32_t getVerticesCount() const
31  {
32  return vertex.size();
33  }
34  void reset();
35  int32_t WeldVertex(const Vertex *v);
36 
37  int32_t LocateVertexInBucket(const Vertex& v, uint32_t bucket, bool& isAllDataTheSame);
38 
39  int32_t LocateVertexInBucketOnlyPosition(const Vertex& v, uint32_t bucket, bool& isAllDataTheSame);
40 
41 
42  private:
43  // Computes hash bucket index in range [0, NUM_BUCKETS-1]
44  //int32_t ComputeHashBucketIndex(const Vertex& v)
45  int32_t ComputeHashBucketIndex(int32_t x, int32_t y, int32_t z);
46 
47  void AddVertexToBucket(const Vertex& v, uint32_t bucket);
48 
49  std::vector<int32_t> first; // start of linked list for each bucket
50  std::vector<int32_t> next; // links each vertex to next in linked list
51  std::vector<Vertex> vertex; // unique vertices within tolerance
52 
53  const uint32_t maxVertexCount; // max number of vertices that can be welded at once
54  const uint32_t maxBucketCount; // number of hash buckets to map grid cells into
55  const float gridCellSizeInv; // grid cell size; must be at least 2*WELD_EPSILON
56  const float weldEpsilon; // radius around vertex defining welding neighborhood
57  const float auxEpsilon; // epsilon for normal and uv of vertex
58 
59  LOCATE_CALLBACK locateCallback;
60  };
61 
62  class BooleanToolV2 : public Fracturer
63  {
64  public:
65 
66  struct Mode
67  {
68  int32_t ca, cb, ci;
69  Mode() { ca = 0; cb = 0; ci = -1; };
70  Mode(int32_t a, int32_t b, int32_t c) : ca(a), cb(b), ci(c)
71  {
72  }
73 
74  static Mode Intersection()
75  {
76  return Mode(0, 0, 1);
77  }
78 
82  static Mode Union()
83  {
84  return Mode(1, 1, -1);
85  }
89  static Mode Difference()
90  {
91  return Mode(1, 0, -1);
92  }
93  };
94 
95  BooleanToolV2();
96 
97  void release();
98 
103  const Mesh* mMeshA;
104  const Mesh* mMeshB;
107  //const PreparedMesh* mPreparedA;
108  //const PreparedMesh* mPreparedB;
109 
110 
114  void makeFacetFacetTests(BooleanToolOutputData* outputData, int32_t threadId, int32_t threadCount);
115  void retain(bool isA, BooleanToolOutputData* outputData, int32_t threadId, int32_t threadCount,
116  const DamagePattern* pattern = nullptr, int32_t chunk = -1);
117 
121  //Nv::Blast::Mesh* getMesh();
122 
123 
124  private:
125 
126  int32_t computeV03(const PxVec3& point);
127  int32_t computeV30(const PxVec3& point);
128 
129 
133  void computeRetained(const Mesh* mesh, const physx::PxBounds3& bMeshBoudning,
134  int32_t(BooleanToolV2::*computeV3)(const physx::PxVec3&), int32_t btC, int32_t btCI, int32_t parentFacetOffset,
135  BooleanToolOutputData* outputData, int32_t threadId, int32_t threadCount,
136  struct FaceOrientation* fo = nullptr, const std::vector<bool>* validAdjacentFacet = nullptr);
137 
138 
140 
143  float* sx1;
144  float* sy1;
145  float* ex1;
146  float* ey1;
147  float* px1;
148  float* py1;
149  float* pt1;
150  float* resy1;
151  int32_t* winding1;
152  int32_t* projectedWinding1;
153 
154 
155  float* sx2;
156  float* sy2;
157  float* ex2;
158  float* ey2;
159  float* px2;
160  float* py2;
161  float* pt2;
162  float* resy2;
163  int32_t* winding2;
164  int32_t* projectedWinding2;
165 
166  uint32_t* edgeFacetTestA;
167  uint32_t* edgeFacetTestB;
168 
169 
173  int32_t* edgeCrossCheckTest;
174  Vertex* edgeCrossA;
175  Vertex* edgeCrossB;
176 
177  Mode mToolMode;
178  };
179 
181  {
182  public:
183  TriangulatorV2();
184 
185  void release();
186 
187  uint32_t build(const BooleanResultEdge* edges, uint32_t inEdgeCount, const Vertex* inVertices, Vertex* outWeldedVrts, uint32_t& vcount, uint32_t* outTriangles, PerTriangleAdditionalData* adata, uint32_t maxTcount, const Mesh* ma, const Mesh* mb);
188 
190  {
191  uint32_t point;
192  uint32_t nextPoint;
193  uint32_t prevPoint;
194  };
195 
197  uint32_t weldedCount;
198  uint32_t* triangleIndices;
199  uint32_t triangleCount;
200 
201  private:
202 
203  void triangulatePolygonWithEarClipping(ProjectionDirections dir);
204 
205  LinkedListElement facetList[1024];
206  uint32_t facetListSize;
207  uint32_t pointIndicesList[1024];
208  uint32_t pointCount;
209 
210  physx::PxVec2 projectedPointList[1024];
211  uint32_t projectedPointCount;
212 
213  uint32_t visitedFlagValue[1024];
214  uint32_t currentFlagValue;
215 
216 
217 
218  Edge* weldedEdges;
219 
220 
221  const BooleanResultEdge* mInpEdges;
222  uint32_t mInpEdgeCount;
223  uint32_t maxTriangleCount;
224 
225  const Mesh* meshA;
226  const Mesh* meshB;
227 
228  VertexWelding wldg;
229  };
230 
231  }
232 }
233 
Definition: NvBlastExtRTGeometry.h:18
-
ProjectionDirections
Definition: NvBlastExtAuthoringInternalCommon.h:92
+
ProjectionDirections
Definition: NvBlastExtAuthoringInternalCommon.h:93
int32_t WeldVertex(const Vertex *v)
Definition: NvBlastExtRT.h:68
uint32_t * triangleIndices
Definition: NvBlastExtRTGeometry.h:198
diff --git a/docs/source_docs/files/_nv_blast_family_8h_source.html b/docs/source_docs/files/_nv_blast_family_8h_source.html index 34d4003..cd77417 100755 --- a/docs/source_docs/files/_nv_blast_family_8h_source.html +++ b/docs/source_docs/files/_nv_blast_family_8h_source.html @@ -54,7 +54,7 @@ $(document).ready(function(){initNavTree('_nv_blast_family_8h_source.html','');}
void fractureNoEvents(uint32_t chunkFractureCount, const NvBlastChunkFractureData *chunkFractures, Actor *filterActor, NvBlastLog logFn)
bool isActorActive(uint32_t index) const
Definition: NvBlastFamily.h:367
uint32_t getGetNodeActorIndex(uint32_t nodeIndex) const
Definition: NvBlastFamily.h:397
-
uint32_t getBondCount() const
Definition: NvBlastAsset.h:276
+
uint32_t getBondCount() const
Definition: NvBlastAsset.h:277
NV_INLINE bool isInvalidIndex(T index)
Definition: NvBlastIndexFns.h:57
void(* NvBlastLog)(int type, const char *msg, const char *file, int line)
Definition: NvBlastTypes.h:63
@@ -70,7 +70,7 @@ $(document).ready(function(){initNavTree('_nv_blast_family_8h_source.html','');}
Definition: NvBlastTypes.h:98
uint32_t getActorBufferSize() const
Definition: NvBlastFamily.h:360
-
uint32_t m_firstSubsupportChunkIndex
Definition: NvBlastAsset.h:206
+
uint32_t m_firstSubsupportChunkIndex
Definition: NvBlastAsset.h:207
const Asset * m_asset
Definition: NvBlastFamily.h:148
Actor * getActorByIndex(uint32_t index) const
Definition: NvBlastFamily.h:374
@@ -80,19 +80,19 @@ $(document).ready(function(){initNavTree('_nv_blast_family_8h_source.html','');}
uint32_t m_nodeCount
Definition: NvBlastSupportGraph.h:81
NvBlastID m_assetID
Definition: NvBlastFamily.h:66
Definition: NvBlastTypes.h:69
-
uint32_t getLowerSupportChunkCount() const
Definition: NvBlastAsset.h:270
+
uint32_t getLowerSupportChunkCount() const
Definition: NvBlastAsset.h:271
Definition: NvBlastTypes.h:152
Definition: NvBlastTypes.h:439
NvBlastBlockData(FamilyGraph, m_familyGraphOffset, getFamilyGraph)
float * getSubsupportChunkHealths() const
Definition: NvBlastFamily.h:113
-
SupportGraph m_graph
Definition: NvBlastAsset.h:196
+
SupportGraph m_graph
Definition: NvBlastAsset.h:197
Definition: NvBlastTypes.h:286
Definition: NvBlastTypes.h:468
Definition: NvBlastActor.h:58
uint64_t m_runtimePlaceholder
Definition: NvBlastFamily.h:149
-
uint32_t getUpperSupportChunkCount() const
Definition: NvBlastAsset.h:264
+
uint32_t getUpperSupportChunkCount() const
Definition: NvBlastAsset.h:265
-
uint32_t m_chunkCount
Definition: NvBlastAsset.h:191
+
uint32_t m_chunkCount
Definition: NvBlastAsset.h:192
int32_t atomicDecrement(volatile int32_t *val)
void returnActor(Actor &actor)
Definition: NvBlastFamily.h:348
diff --git a/docs/source_docs/files/class_nv_1_1_blast_1_1_asset.html b/docs/source_docs/files/class_nv_1_1_blast_1_1_asset.html index 342205d..23e9517 100755 --- a/docs/source_docs/files/class_nv_1_1_blast_1_1_asset.html +++ b/docs/source_docs/files/class_nv_1_1_blast_1_1_asset.html @@ -605,7 +605,7 @@ getChunks returns an array of size m_chunkCount.

Tests a set of chunk descriptors to see if chunks are in valid chunk order.

-Chunk order conditions checked: 1. 'all chunks with same parent index should go in a row'. 2. 'root chunks should go first'. 3. 'upper-support chunks should come before subsupport chunks'.

+Chunk order conditions checked: 1. 'all chunks with same parent index should go in a row'. 2. 'chunks should come after their parents'. 3. 'root chunks should go first'. 4. 'upper-support chunks should come before subsupport chunks'.

Parameters:
diff --git a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool-members.html b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool-members.html index 52dcf12..831274c 100755 --- a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool-members.html +++ b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool-members.html @@ -64,6 +64,7 @@ + diff --git a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.html b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.html index 6dc496c..fb3d031 100755 --- a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.html +++ b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.html @@ -104,6 +104,8 @@ Inheritance diagram for Nv::Blast::FractureTool: + + @@ -879,6 +881,44 @@ Replaces an material id on faces with a new one Reset FractureTool state.

Implemented in Nv::Blast::FractureToolImpl.

+ +

+ +

+
+
[in] chunkCount The number of chunk descriptors.
release()=0Nv::Blast::FractureTool [pure virtual]
replaceMaterialId(int32_t oldMaterialId, int32_t newMaterialId)=0Nv::Blast::FractureTool [pure virtual]
reset()=0Nv::Blast::FractureTool [pure virtual]
setApproximateBonding(uint32_t chunkIndex, bool useApproximateBonding)=0Nv::Blast::FractureTool [pure virtual]
setChunkMesh(const Mesh *mesh, int32_t parentId)=0Nv::Blast::FractureTool [pure virtual]
setInteriorMaterialId(int32_t materialId)=0Nv::Blast::FractureTool [pure virtual]
setRemoveIslands(bool isRemoveIslands)=0Nv::Blast::FractureTool [pure virtual]
virtual void reset ()=0
virtual bool setApproximateBonding (uint32_t chunkIndex, bool useApproximateBonding)=0
virtual int32_t setChunkMesh (const Mesh *mesh, int32_t parentId)=0
virtual void setInteriorMaterialId (int32_t materialId)=0
+ + + + + + + + + + + + + + + + + +
virtual bool Nv::Blast::FractureTool::setApproximateBonding (uint32_t  chunkIndex,
bool  useApproximateBonding 
) [pure virtual]
+
+
+ +

+Set the APPROXIMATE_BONDING flag in the chunk's ChunkInfo

Parameters:
+ + + +
[in] chunkIndex chunk index - use getChunkIndex(ID)
[in] useApproximateBonding value of flag to set
+
+
Returns:
true if the chunk ID is found, false otherwise
+ +

Implemented in Nv::Blast::FractureToolImpl.

+

diff --git a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.js b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.js index b4a1a8f..a3f0bbe 100755 --- a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.js +++ b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool.js @@ -24,6 +24,7 @@ var class_nv_1_1_blast_1_1_fracture_tool = [ "release", "class_nv_1_1_blast_1_1_fracture_tool.html#a78da4a0d726ec1b541166cd3c46df67e", null ], [ "replaceMaterialId", "class_nv_1_1_blast_1_1_fracture_tool.html#a78194aeece0c12c2035c79458ff49c9f", null ], [ "reset", "class_nv_1_1_blast_1_1_fracture_tool.html#ab462c92fa47a5359bf3d19cf44af80f4", null ], + [ "setApproximateBonding", "class_nv_1_1_blast_1_1_fracture_tool.html#a33c19de2bc8ea52394651d184076db5c", null ], [ "setChunkMesh", "class_nv_1_1_blast_1_1_fracture_tool.html#aecd9be996bba9329418fd91db8235ebe", null ], [ "setInteriorMaterialId", "class_nv_1_1_blast_1_1_fracture_tool.html#ac8c4f90133fdf32969cad6e4c520414f", null ], [ "setRemoveIslands", "class_nv_1_1_blast_1_1_fracture_tool.html#a251738022e498b819e88536577470735", null ], diff --git a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl-members.html b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl-members.html index 5834f88..62ca715 100755 --- a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl-members.html +++ b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl-members.html @@ -73,6 +73,7 @@ release() overrideNv::Blast::FractureToolImpl [virtual] replaceMaterialId(int32_t oldMaterialId, int32_t newMaterialId) overrideNv::Blast::FractureToolImpl [virtual] reset() overrideNv::Blast::FractureToolImpl [virtual] + setApproximateBonding(uint32_t chunkId, bool useApproximateBonding) overrideNv::Blast::FractureToolImpl [virtual] setChunkMesh(const Mesh *mesh, int32_t parentId) overrideNv::Blast::FractureToolImpl [virtual] setInteriorMaterialId(int32_t materialId) overrideNv::Blast::FractureToolImpl [virtual] setRemoveIslands(bool isRemoveIslands) overrideNv::Blast::FractureToolImpl [virtual] diff --git a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.html b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.html index 4ca24b9..b3a36a2 100755 --- a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.html +++ b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.html @@ -106,6 +106,8 @@ Inheritance diagram for Nv::Blast::FractureToolImpl:

void reset () override +bool setApproximateBonding (uint32_t chunkId, bool useApproximateBonding) override + int32_t setChunkMesh (const Mesh *mesh, int32_t parentId) override void setInteriorMaterialId (int32_t materialId) override @@ -920,6 +922,44 @@ Replaces an material id on faces with a new one Reset FractureTool state.

Implements Nv::Blast::FractureTool.

+
+

+ +

+
+ + + + + + + + + + + + + + + + + + +
bool Nv::Blast::FractureToolImpl::setApproximateBonding (uint32_t  chunkIndex,
bool  useApproximateBonding 
) [override, virtual]
+
+
+ +

+Set the APPROXIMATE_BONDING flag in the chunk's ChunkInfo

Parameters:
+ + + +
[in] chunkIndex chunk index - use getChunkIndex(ID)
[in] useApproximateBonding value of flag to set
+
+
Returns:
true if the chunk ID is found, false otherwise
+ +

Implements Nv::Blast::FractureTool.

+

diff --git a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.js b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.js index 3bba54a..f32a47e 100755 --- a/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.js +++ b/docs/source_docs/files/class_nv_1_1_blast_1_1_fracture_tool_impl.js @@ -25,6 +25,7 @@ var class_nv_1_1_blast_1_1_fracture_tool_impl = [ "release", "class_nv_1_1_blast_1_1_fracture_tool_impl.html#a05d2e5fd981d54d55ee5dbc5bf454a50", null ], [ "replaceMaterialId", "class_nv_1_1_blast_1_1_fracture_tool_impl.html#abe1f6bf365964825a2c939e22c85d96a", null ], [ "reset", "class_nv_1_1_blast_1_1_fracture_tool_impl.html#a1ccbcbfde4e58f8357a589ae56ff043f", null ], + [ "setApproximateBonding", "class_nv_1_1_blast_1_1_fracture_tool_impl.html#a3fdd1a0df69a82898a6ec8c0f51094fc", null ], [ "setChunkMesh", "class_nv_1_1_blast_1_1_fracture_tool_impl.html#ac466495627ca99252433c7e1c702c7f9", null ], [ "setInteriorMaterialId", "class_nv_1_1_blast_1_1_fracture_tool_impl.html#ac9c8e18748b18fa6dd29a328eaf63026", null ], [ "setRemoveIslands", "class_nv_1_1_blast_1_1_fracture_tool_impl.html#a92dec92822ab9e0807400a7d63bfc553", null ], diff --git a/docs/source_docs/files/functions_0x61.html b/docs/source_docs/files/functions_0x61.html index 65df3cd..71ef847 100755 --- a/docs/source_docs/files/functions_0x61.html +++ b/docs/source_docs/files/functions_0x61.html @@ -254,52 +254,52 @@ Here is a list of all class members with links to the classes they belong to:

  • ApexImportTool() : Nv::Blast::ApexImporter::ApexImportTool
  • appendMesh() -: Nv::Blast::FbxFileWriter -, Nv::Blast::ObjFileWriter +: Nv::Blast::ObjFileWriter , Nv::Blast::IMeshFileWriter , Nv::Blast::FbxFileWriter -, Nv::Blast::ObjFileWriter
  • applyDamage() : Nv::Blast::ExtImpactDamageManager
  • applyFracture() : Nv::Blast::TkActorImpl -, Nv::Blast::Actor , Nv::Blast::TkFamily -, Nv::Blast::TkActor , Nv::Blast::FamilyHeader +, Nv::Blast::TkActor +, Nv::Blast::Actor
  • applyNoise() : Nv::Blast::MeshNoiser
  • applySyncBuffer() : Nv::Blast::ExtSync +
  • APPROXIMATE_BONDING +: Nv::Blast::ChunkInfo
  • area : NvBlastBond
  • asReader() -: Nv::Blast::Serialization::NvBlastSupportGraph::NvBlastSupportGraph::Builder +: Nv::Blast::Serialization::PxConvexMeshGeometry::PxConvexMeshGeometry::Builder +, Nv::Blast::Serialization::PxQuat::PxQuat::Builder +, Nv::Blast::Serialization::NvBlastSupportGraph::NvBlastSupportGraph::Builder , Nv::Blast::Serialization::ExtPxAsset::ExtPxAsset::Builder -, Nv::Blast::Serialization::PxConvexMeshGeometry::PxConvexMeshGeometry::Builder -, Nv::Blast::Serialization::TkAsset::TkAsset::Builder , Nv::Blast::Serialization::PxTransform::PxTransform::Builder , Nv::Blast::Serialization::ExtPxChunk::ExtPxChunk::Builder -, Nv::Blast::Serialization::NvBlastChunk::NvBlastChunk::Builder -, Nv::Blast::Serialization::Asset::Asset::Builder +, Nv::Blast::Serialization::ExtPxSubchunk::ExtPxSubchunk::Builder , Nv::Blast::Serialization::UUID::UUID::Builder , Nv::Blast::Serialization::NvBlastBond::NvBlastBond::Builder +, Nv::Blast::Serialization::NvBlastDataBlock::NvBlastDataBlock::Builder +, Nv::Blast::Serialization::NvBlastChunk::NvBlastChunk::Builder , Nv::Blast::Serialization::PxMeshScale::PxMeshScale::Builder -, Nv::Blast::Serialization::ExtPxSubchunk::ExtPxSubchunk::Builder -, Nv::Blast::Serialization::TkAssetJointDesc::TkAssetJointDesc::Builder , Nv::Blast::Serialization::PxVec3::PxVec3::Builder -, Nv::Blast::Serialization::NvBlastDataBlock::NvBlastDataBlock::Builder -, Nv::Blast::Serialization::PxQuat::PxQuat::Builder -
  • Asset -: Nv::Blast::LlObjectTypeID +, Nv::Blast::Serialization::TkAsset::TkAsset::Builder +, Nv::Blast::Serialization::Asset::Asset::Builder +, Nv::Blast::Serialization::TkAssetJointDesc::TkAssetJointDesc::Builder +
  • Asset() +: Nv::Blast::Serialization::Asset +, Nv::Blast::ExtPxObjectTypeID
  • asset -: Nv::Blast::ExporterMeshData +: Nv::Blast::TkActorDesc
  • Asset -: Nv::Blast::ExtPxObjectTypeID -, Nv::Blast::Serialization::Asset -, Nv::Blast::TkObjectTypeID +: Nv::Blast::TkObjectTypeID +, Nv::Blast::LlObjectTypeID
  • asset -: Nv::Blast::TkActorDesc +: Nv::Blast::ExporterMeshData
  • Asset : Nv::Blast::TkTypeIndex
  • asset @@ -316,12 +316,14 @@ Here is a list of all class members with links to the classes they belong to:
  • assetToFractureChunkIdMap : Nv::Blast::AuthoringResult
  • at() -: Nv::Blast::FixedArray< T > -, btAlignedObjectArray< T > +: btAlignedObjectArray< T > +, Nv::Blast::FixedArray< T > +, btAlignedObjectArray< T > +, Nv::Blast::FixedArray< T >
  • attachPositions : Nv::Blast::TkJointDesc -, Nv::Blast::TkJointData , Nv::Blast::TkAssetJointDesc +, Nv::Blast::TkJointData
  • AVERAGE : Nv::Blast::BondGenerationConfig diff --git a/docs/source_docs/files/functions_0x63.html b/docs/source_docs/files/functions_0x63.html index 0cf2b1d..c932540 100755 --- a/docs/source_docs/files/functions_0x63.html +++ b/docs/source_docs/files/functions_0x63.html @@ -278,10 +278,10 @@ Here is a list of all class members with links to the classes they belong to: , VHACD::VoxelSet , VHACD::TetrahedronSet
  • ComputeVolume() -: VHACD::Mesh +: VHACD::PrimitiveSet +, VHACD::Mesh , VHACD::VoxelSet , VHACD::TetrahedronSet -, VHACD::PrimitiveSet
  • concavity : Nv::Blast::ConvexDecompositionParams
  • Cone @@ -295,8 +295,8 @@ Here is a list of all class members with links to the classes they belong to:
  • contactOffset : Nv::Blast::ExtPxShapeDescTemplate
  • Convert() -: VHACD::Volume -, VHACD::TetrahedronSet +: VHACD::TetrahedronSet +, VHACD::Volume , VHACD::PrimitiveSet , VHACD::VoxelSet , VHACD::Volume @@ -314,68 +314,63 @@ Here is a list of all class members with links to the classes they belong to: : Nv::Blast::BooleanToolOutputDataImpl , Nv::Blast::BooleanToolOutputData
  • Count -: Nv::Blast::ActorSerializationFormat -, NvBlastDataBlock +: NvBlastDataBlock , Nv::Blast::ExtSyncEventType +, Nv::Blast::ActorSerializationFormat
  • create() -: Nv::Blast::ExtPxAsset +: Nv::Blast::ExtPxAsset +
  • Create() +: VHACD::TetrahedronSet +
  • create() +: Nv::Blast::ExtPxAsset , Nv::Blast::final -, Nv::Blast::Actor -, Nv::Blast::ExtStressSolver
  • Create() : VHACD::PrimitiveSet -, VHACD::TetrahedronSet
  • create() -: Nv::Blast::ExtPxAsset -, Nv::Blast::ExtSync -, Nv::Blast::ExtPxAsset -, Nv::Blast::ExtPxManager +: Nv::Blast::ExtGroupTaskManager , Nv::Blast::Asset -, Nv::Blast::ExtPxStressSolver +, Nv::Blast::ExtPxManager +, Nv::Blast::ExtStressSolver +, Nv::Blast::Actor , Nv::Blast::TkActorImpl -, Nv::Blast::ExtGroupTaskManager +, Nv::Blast::ExtSync +, Nv::Blast::ExtPxStressSolver , Nv::Blast::ExtPxAsset +, Nv::Blast::ExtImpactDamageManager
  • Create() : VHACD::VoxelSet -
  • create() -: Nv::Blast::ExtImpactDamageManager
  • createActor() -: Nv::Blast::TkFrameworkImpl -, Nv::Blast::TkFramework +: Nv::Blast::TkFramework +, Nv::Blast::TkFrameworkImpl
  • createAsset() : Nv::Blast::TkFrameworkImpl , Nv::Blast::TkFramework -, Nv::Blast::TkFrameworkImpl
  • createBondBetweenMeshes() -: Nv::Blast::BlastBondGeneratorImpl -, Nv::Blast::BlastBondGenerator +: Nv::Blast::BlastBondGenerator , Nv::Blast::BlastBondGeneratorImpl -, Nv::Blast::BlastBondGenerator
  • createChunkMesh() : Nv::Blast::FractureTool , Nv::Blast::FractureToolImpl
  • createCollisionBuilder() : Nv::Blast::ExtPxManager -
  • CREATED_BY_ISLAND_DETECTOR -: Nv::Blast::ChunkInfo
  • createFamily() -: Nv::Blast::ExtPxManager -, Nv::Blast::final +: Nv::Blast::final +, Nv::Blast::ExtPxManager
  • createGroup() : Nv::Blast::TkFrameworkImpl , Nv::Blast::TkFramework
  • createJoint() -: Nv::Blast::TkFramework -, Nv::Blast::TkFrameworkImpl +: Nv::Blast::TkFrameworkImpl , Nv::Blast::ExtPxManager +, Nv::Blast::TkFramework , Nv::Blast::final
  • createNewMesh() : Nv::Blast::BooleanEvaluator
  • createRaycastMesh() -: VHACD::RaycastMesh +: VHACD::RaycastMesh
  • createRequiredScratch() -: Nv::Blast::Actor -, Nv::Blast::Asset +: Nv::Blast::Asset +, Nv::Blast::Actor
  • Current : Nv::Blast::ActorSerializationFormat
  • cut() diff --git a/docs/source_docs/files/functions_0x69.html b/docs/source_docs/files/functions_0x69.html index d75f6f7..85e4bcd 100755 --- a/docs/source_docs/files/functions_0x69.html +++ b/docs/source_docs/files/functions_0x69.html @@ -229,10 +229,10 @@ Here is a list of all class members with links to the classes they belong to: : Nv::Blast::ExtTaskSync
  • isDouble() : FLOAT_MATH::fm_VertexIndex -
  • IsEmpty() -: VHACD::CircularList< T >
  • isEmpty() : Nv::Blast::DList +
  • IsEmpty() +: VHACD::CircularList< T >
  • IsFlat() : VHACD::ICHull
  • IsInside() diff --git a/docs/source_docs/files/functions_0x70.html b/docs/source_docs/files/functions_0x70.html index eff21f9..8fda96a 100755 --- a/docs/source_docs/files/functions_0x70.html +++ b/docs/source_docs/files/functions_0x70.html @@ -91,11 +91,11 @@ Here is a list of all class members with links to the classes they belong to: , NvcTransform
  • Parameters() : VHACD::IVHACD::IVHACD::Parameters +
  • Parent +: Nv::Blast::Asset::Asset::ChunkAnnotation
  • parent : Nv::Blast::ChunkInfo , Nv::Blast::EdgeWithParent -
  • Parent -: Nv::Blast::Asset::Asset::ChunkAnnotation
  • parentChunkIndex : NvBlastChunkDesc , NvBlastChunk @@ -174,10 +174,10 @@ Here is a list of all class members with links to the classes they belong to: : Nv::Blast::Separation , Nv::Blast::PlaneChunkIndexer , Nv::Blast::HullPolygon -
  • Point -: Nv::Blast::DamagePattern
  • point : Nv::Blast::TriangulatorV2::TriangulatorV2::LinkedListElement +
  • Point +: Nv::Blast::DamagePattern
  • POINT2D() : Nv::Blast::POINT2D
  • pointer @@ -267,10 +267,11 @@ Here is a list of all class members with links to the classes they belong to:
  • push_back() : btAlignedObjectArray< T >
  • pushBack() -: Nv::Blast::FixedArray< T > -, Nv::Blast::FixedQueue< T > +: Nv::Blast::FixedQueue< T >
  • PushBack() : VHACD::SArray< T, N > +
  • pushBack() +: Nv::Blast::FixedArray< T >
  • pxAsset : Nv::Blast::ExtPxFamilyDesc
  • pxChunks diff --git a/docs/source_docs/files/functions_0x72.html b/docs/source_docs/files/functions_0x72.html index 60db7b8..864782a 100755 --- a/docs/source_docs/files/functions_0x72.html +++ b/docs/source_docs/files/functions_0x72.html @@ -324,10 +324,10 @@ Here is a list of all class members with links to the classes they belong to:
  • resetEdges() : Nv::Blast::BooleanToolOutputDataImpl , Nv::Blast::BooleanToolOutputData -
  • resize() -: btAlignedObjectArray< T >
  • Resize() : VHACD::SArray< T, N > +
  • resize() +: btAlignedObjectArray< T >
  • ResizePoints() : VHACD::Mesh
  • ResizeTriangles() diff --git a/docs/source_docs/files/functions_0x73.html b/docs/source_docs/files/functions_0x73.html index 89fac2d..515b832 100755 --- a/docs/source_docs/files/functions_0x73.html +++ b/docs/source_docs/files/functions_0x73.html @@ -154,6 +154,9 @@ Here is a list of all class members with links to the classes they belong to: : Nv::Blast::TkJointImpl
  • setAllNodesInfoFromLL() : Nv::Blast::ExtStressSolver +
  • setApproximateBonding() +: Nv::Blast::FractureTool +, Nv::Blast::FractureToolImpl
  • setAsset() : Nv::Blast::Serialization::ExtPxAsset::ExtPxAsset::Builder
  • setAssetLL() @@ -175,8 +178,8 @@ Here is a list of all class members with links to the classes they belong to: : Nv::Blast::FractureTool , Nv::Blast::FractureToolImpl
  • setChunks() -: Nv::Blast::Serialization::Asset::Asset::Builder -, Nv::Blast::Serialization::ExtPxAsset::ExtPxAsset::Builder +: Nv::Blast::Serialization::ExtPxAsset::ExtPxAsset::Builder +, Nv::Blast::Serialization::Asset::Asset::Builder
  • setConvexMesh() : Nv::Blast::Serialization::PxConvexMeshGeometry::PxConvexMeshGeometry::Builder
  • setCount() @@ -264,8 +267,8 @@ Here is a list of all class members with links to the classes they belong to:
  • setRotation() : Nv::Blast::Serialization::PxMeshScale::PxMeshScale::Builder
  • setScale() -: Nv::Blast::Serialization::PxMeshScale::PxMeshScale::Builder -, Nv::Blast::Serialization::PxConvexMeshGeometry::PxConvexMeshGeometry::Builder +: Nv::Blast::Serialization::PxConvexMeshGeometry::PxConvexMeshGeometry::Builder +, Nv::Blast::Serialization::PxMeshScale::PxMeshScale::Builder
  • setSerializationEncoding() : Nv::Blast::ExtSerialization
  • setSettings() @@ -274,19 +277,19 @@ Here is a list of all class members with links to the classes they belong to:
  • setSize() : Nv::Blast::Serialization::NvBlastDataBlock::NvBlastDataBlock::Builder
  • setSmoothingGroup() -: Nv::Blast::Mesh -, Nv::Blast::MeshImpl +: Nv::Blast::MeshImpl +, Nv::Blast::Mesh
  • setSourceMesh() -: Nv::Blast::FractureToolImpl -, Nv::Blast::FractureTool +: Nv::Blast::FractureTool +, Nv::Blast::FractureToolImpl
  • setState() : Nv::Blast::SpatialAccelerator , Nv::Blast::DummyAccelerator , Nv::Blast::GridWalker -, Nv::Blast::SweepingAccelerator +, Nv::Blast::SweepingAccelerator , Nv::Blast::BBoxBasedAccelerator -, Nv::Blast::GridWalker -, Nv::Blast::SweepingAccelerator +, Nv::Blast::SweepingAccelerator +, Nv::Blast::DummyAccelerator
  • setStencil() : Nv::Blast::VoronoiSitesGenerator , Nv::Blast::VoronoiSitesGeneratorImpl @@ -299,8 +302,8 @@ Here is a list of all class members with links to the classes they belong to:
  • setType() : Nv::Blast::Serialization::PxConvexMeshGeometry::PxConvexMeshGeometry::Builder
  • setUniformHealth() -: Nv::Blast::final -, Nv::Blast::ExtPxAsset +: Nv::Blast::ExtPxAsset +, Nv::Blast::final
  • setup() : Nv::Blast::ExtGroupWorkerTask
  • setValue() @@ -311,14 +314,14 @@ Here is a list of all class members with links to the classes they belong to:
  • setWorkerCount() : Nv::Blast::TkGroup
  • setX() -: Nv::Blast::Serialization::PxQuat::PxQuat::Builder -, Nv::Blast::Serialization::PxVec3::PxVec3::Builder +: Nv::Blast::Serialization::PxVec3::PxVec3::Builder +, Nv::Blast::Serialization::PxQuat::PxQuat::Builder
  • setY() : Nv::Blast::Serialization::PxQuat::PxQuat::Builder , Nv::Blast::Serialization::PxVec3::PxVec3::Builder
  • setZ() -: Nv::Blast::Serialization::PxVec3::PxVec3::Builder -, Nv::Blast::Serialization::PxQuat::PxQuat::Builder +: Nv::Blast::Serialization::PxQuat::PxQuat::Builder +, Nv::Blast::Serialization::PxVec3::PxVec3::Builder
  • SharedBlock() : Nv::Blast::SharedBlock< T >
  • SharedBuffer() @@ -335,34 +338,34 @@ Here is a list of all class members with links to the classes they belong to: : Nv::Blast::ExtPxShapeDescTemplate
  • size : NvBlastDataBlock -, Nv::Blast::FixedPriorityQueue< Element, Comparator >
  • Size() : VHACD::SArray< T, N >
  • size() -: Nv::Blast::FixedQueue< T > +: btAlignedObjectArray< T > +, Nv::Blast::FixedQueue< T > , Nv::Blast::FixedArray< T > -, btAlignedObjectArray< T > +, Nv::Blast::FixedPriorityQueue< Element, Comparator >
  • skipObject() : Nv::Blast::ExtSerialization
  • slicing() : Nv::Blast::FractureToolImpl , Nv::Blast::FractureTool
  • smoothingGroup -: Nv::Blast::TriangleIndexed -, Nv::Blast::PerTriangleAdditionalData -, Nv::Blast::Triangle +: Nv::Blast::PerTriangleAdditionalData , Nv::Blast::Facet +, Nv::Blast::TriangleIndexed +, Nv::Blast::Triangle
  • smoothingGroups : Nv::Blast::Cutout
  • sortToCCW() : Nv::Blast::TriangleProcessor
  • spawn() -: Nv::Blast::ExtPxFamily -, Nv::Blast::final -
  • split() -: Nv::Blast::Actor +: Nv::Blast::final +, Nv::Blast::ExtPxFamily
  • Split : Nv::Blast::TkEvent +
  • split() +: Nv::Blast::Actor
  • splitRequiredScratch() : Nv::Blast::Actor
  • start @@ -382,8 +385,8 @@ Here is a list of all class members with links to the classes they belong to:
  • stressLinearFactor : Nv::Blast::ExtStressSolverSettings
  • subchunkCount -: Nv::Blast::ExtPxAssetDesc::ExtPxAssetDesc::ChunkDesc -, Nv::Blast::ExtPxChunk +: Nv::Blast::ExtPxChunk +, Nv::Blast::ExtPxAssetDesc::ExtPxAssetDesc::ChunkDesc
  • subchunks : Nv::Blast::ExtPxAssetDesc::ExtPxAssetDesc::ChunkDesc
  • subgraphShaderFunction @@ -395,14 +398,13 @@ Here is a list of all class members with links to the classes they belong to:
  • submeshOffsets : Nv::Blast::ExporterMeshData
  • subscribe() -: Nv::Blast::final -, Nv::Blast::ExtPxFamily -, Nv::Blast::ExtPxManager +: Nv::Blast::ExtPxFamily , Nv::Blast::final -
  • subtype -: Nv::Blast::TkJointUpdateEvent +, Nv::Blast::ExtPxManager
  • Subtype : Nv::Blast::TkJointUpdateEvent +
  • subtype +: Nv::Blast::TkJointUpdateEvent
  • SuperSupport : Nv::Blast::Asset::Asset::ChunkAnnotation
  • Support diff --git a/docs/source_docs/files/functions_0x74.html b/docs/source_docs/files/functions_0x74.html index b3fc989..2abbf57 100755 --- a/docs/source_docs/files/functions_0x74.html +++ b/docs/source_docs/files/functions_0x74.html @@ -271,24 +271,24 @@ Here is a list of all class members with links to the classes they belong to: : VHACD::Mutex
  • tryRead() : Nv::Blast::ExtInputStream -
  • Type -: Nv::Blast::Serialization::PxConvexMeshGeometry -
  • type -: Nv::Blast::HashMap< Key, Value, HashFn > -, Nv::Blast::HashSet< Key, HashFn > -, Nv::Blast::ExtSyncEvent -
  • Type -: NvBlastMessage
  • type -: Nv::Blast::InlineArray< T, N > -, Nv::Blast::Array< T > +: Nv::Blast::ExtSyncEvent
  • Type : NvBlastDataBlock +, Nv::Blast::TkEvent , Nv::Blast::Serialization::NvBlastDataBlock
  • type +: Nv::Blast::Array< T > +
  • Type +: NvBlastMessage +
  • type : Nv::Blast::TkEvent +, Nv::Blast::InlineArray< T, N > +, Nv::Blast::HashSet< Key, HashFn >
  • Type -: Nv::Blast::TkEvent +: Nv::Blast::Serialization::PxConvexMeshGeometry +
  • type +: Nv::Blast::HashMap< Key, Value, HashFn >
  • TypeCount : Nv::Blast::TkTypeIndex , Nv::Blast::TkEvent diff --git a/docs/source_docs/files/functions_0x75.html b/docs/source_docs/files/functions_0x75.html index 2fd99e2..c613e53 100755 --- a/docs/source_docs/files/functions_0x75.html +++ b/docs/source_docs/files/functions_0x75.html @@ -133,22 +133,21 @@ Here is a list of all class members with links to the classes they belong to:
  • UpperSupport : Nv::Blast::Asset::Asset::ChunkAnnotation
  • userData -: NvBlastBond -, Nv::Blast::ExtPxFamily -, NvBlastChunk +: Nv::Blast::ExtPxFamily +, Nv::Blast::Facet +, Nv::Blast::ExtPxAsset +, Nv::Blast::TkObject +, Nv::Blast::Triangle
  • userdata : NvBlastBondFractureData
  • userData -: Nv::Blast::Facet -, Nv::Blast::TriangleIndexed -, Nv::Blast::TkActorData -, Nv::Blast::TkObject +: NvBlastBond , NvBlastChunkDesc +, NvBlastChunk +, Nv::Blast::TkActorData +, Nv::Blast::TriangleIndexed
  • userdata : NvBlastChunkFractureData -
  • userData -: Nv::Blast::ExtPxAsset -, Nv::Blast::Triangle
  • userIntData : Nv::Blast::TkIdentifiable
  • useSmoothing diff --git a/docs/source_docs/files/functions_0x79.html b/docs/source_docs/files/functions_0x79.html index 71e2468..5e86a8d 100755 --- a/docs/source_docs/files/functions_0x79.html +++ b/docs/source_docs/files/functions_0x79.html @@ -86,20 +86,23 @@ Here is a list of all class members with links to the classes they belong to:

    - y -

    diff --git a/docs/source_docs/files/functions_a.html b/docs/source_docs/files/functions_a.html index 5f54e30..56891e9 100755 --- a/docs/source_docs/files/functions_a.html +++ b/docs/source_docs/files/functions_a.html @@ -314,8 +314,8 @@ $(document).ready(function(){initNavTree('functions_a.html','');}); : Nv::Blast::ApexImporter::ApexImportTool
  • appendMesh() -: Nv::Blast::FbxFileWriter -, Nv::Blast::IMeshFileWriter +: Nv::Blast::FbxFileWriter +, Nv::Blast::IMeshFileWriter , Nv::Blast::ObjFileWriter
  • applyDamage() @@ -334,6 +334,9 @@ $(document).ready(function(){initNavTree('functions_a.html','');});
  • applySyncBuffer() : Nv::Blast::ExtSync
  • +
  • APPROXIMATE_BONDING +: Nv::Blast::ChunkInfo +
  • area : NvBlastBond
  • diff --git a/docs/source_docs/files/functions_c.html b/docs/source_docs/files/functions_c.html index 4b4b425..adeecad 100755 --- a/docs/source_docs/files/functions_c.html +++ b/docs/source_docs/files/functions_c.html @@ -361,7 +361,7 @@ $(document).ready(function(){initNavTree('functions_c.html','');}); , Nv::Blast::ExtDamageAcceleratorAABBTree , Nv::Blast::ExtGroupTaskManager , Nv::Blast::ExtImpactDamageManager -, Nv::Blast::ExtPxAsset +, Nv::Blast::ExtPxAsset , Nv::Blast::ExtPxManager , Nv::Blast::ExtPxStressSolver , Nv::Blast::ExtStressSolver @@ -378,12 +378,12 @@ $(document).ready(function(){initNavTree('functions_c.html','');}); , Nv::Blast::TkFrameworkImpl
  • createAsset() -: Nv::Blast::TkFramework +: Nv::Blast::TkFramework , Nv::Blast::TkFrameworkImpl
  • createBondBetweenMeshes() -: Nv::Blast::BlastBondGenerator -, Nv::Blast::BlastBondGeneratorImpl +: Nv::Blast::BlastBondGenerator +, Nv::Blast::BlastBondGeneratorImpl
  • createChunkMesh() : Nv::Blast::FractureTool @@ -392,9 +392,6 @@ $(document).ready(function(){initNavTree('functions_c.html','');});
  • createCollisionBuilder() : Nv::Blast::ExtPxManager
  • -
  • CREATED_BY_ISLAND_DETECTOR -: Nv::Blast::ChunkInfo -
  • createFamily() : Nv::Blast::ExtPxManager , Nv::Blast::ExtPxManagerImpl diff --git a/docs/source_docs/files/functions_eval.html b/docs/source_docs/files/functions_eval.html index 746b31e..8c059dc 100755 --- a/docs/source_docs/files/functions_eval.html +++ b/docs/source_docs/files/functions_eval.html @@ -80,11 +80,13 @@

    - a -

    diff --git a/docs/source_docs/files/functions_func_0x69.html b/docs/source_docs/files/functions_func_0x69.html index c84e22a..cf1e0c4 100755 --- a/docs/source_docs/files/functions_func_0x69.html +++ b/docs/source_docs/files/functions_func_0x69.html @@ -185,10 +185,10 @@ : Nv::Blast::ExtTaskSync
  • isDouble() : FLOAT_MATH::fm_VertexIndex -
  • isEmpty() -: Nv::Blast::DList
  • IsEmpty() : VHACD::CircularList< T > +
  • isEmpty() +: Nv::Blast::DList
  • IsFlat() : VHACD::ICHull
  • IsInside() diff --git a/docs/source_docs/files/functions_func_0x70.html b/docs/source_docs/files/functions_func_0x70.html index 2a449f7..b53fb27 100755 --- a/docs/source_docs/files/functions_func_0x70.html +++ b/docs/source_docs/files/functions_func_0x70.html @@ -166,11 +166,12 @@ , Nv::Blast::ExtDamageAcceleratorInternal::ExtDamageAcceleratorInternal::ResultCallback
  • push_back() : btAlignedObjectArray< T > +
  • pushBack() +: Nv::Blast::FixedArray< T >
  • PushBack() : VHACD::SArray< T, N >
  • pushBack() : Nv::Blast::FixedQueue< T > -, Nv::Blast::FixedArray< T >
  • PxConvexMeshGeometry() : Nv::Blast::Serialization::PxConvexMeshGeometry
  • PxMeshScale() diff --git a/docs/source_docs/files/functions_func_0x72.html b/docs/source_docs/files/functions_func_0x72.html index 7364f98..3300bee 100755 --- a/docs/source_docs/files/functions_func_0x72.html +++ b/docs/source_docs/files/functions_func_0x72.html @@ -276,10 +276,10 @@
  • resetEdges() : Nv::Blast::BooleanToolOutputData , Nv::Blast::BooleanToolOutputDataImpl -
  • Resize() -: VHACD::SArray< T, N >
  • resize() : btAlignedObjectArray< T > +
  • Resize() +: VHACD::SArray< T, N >
  • ResizePoints() : VHACD::Mesh
  • ResizeTriangles() diff --git a/docs/source_docs/files/functions_func_0x73.html b/docs/source_docs/files/functions_func_0x73.html index bcc712f..30a8192 100755 --- a/docs/source_docs/files/functions_func_0x73.html +++ b/docs/source_docs/files/functions_func_0x73.html @@ -141,6 +141,9 @@ : Nv::Blast::TkJointImpl
  • setAllNodesInfoFromLL() : Nv::Blast::ExtStressSolver +
  • setApproximateBonding() +: Nv::Blast::FractureTool +, Nv::Blast::FractureToolImpl
  • setAsset() : Nv::Blast::Serialization::ExtPxAsset::ExtPxAsset::Builder
  • setAssetLL() @@ -224,7 +227,7 @@
  • setNodeInfo() : Nv::Blast::ExtStressSolver
  • setNormal() -: Nv::Blast::Serialization::NvBlastBond::NvBlastBond::Builder +: Nv::Blast::Serialization::NvBlastBond::NvBlastBond::Builder
  • setP() : Nv::Blast::Serialization::PxTransform::PxTransform::Builder
  • setPlatformEnabled() @@ -232,17 +235,17 @@
  • SetPoint() : VHACD::Mesh
  • setPointCmpDirection() -: Nv::Blast::BBoxBasedAccelerator +: Nv::Blast::GridWalker , Nv::Blast::SpatialAccelerator , Nv::Blast::DummyAccelerator -, Nv::Blast::GridWalker , Nv::Blast::SweepingAccelerator +, Nv::Blast::BBoxBasedAccelerator
  • setPxActorDesc() -: Nv::Blast::ExtPxFamily -, Nv::Blast::final +: Nv::Blast::final +, Nv::Blast::ExtPxFamily
  • setPxShapeDescTemplate() -: Nv::Blast::final -, Nv::Blast::ExtPxFamily +: Nv::Blast::ExtPxFamily +, Nv::Blast::final
  • setQ() : Nv::Blast::Serialization::PxTransform::PxTransform::Builder
  • setRemoveIslands() @@ -261,24 +264,21 @@
  • setSize() : Nv::Blast::Serialization::NvBlastDataBlock::NvBlastDataBlock::Builder
  • setSmoothingGroup() -: Nv::Blast::MeshImpl -, Nv::Blast::Mesh +: Nv::Blast::Mesh +, Nv::Blast::MeshImpl
  • setSourceMesh() -: Nv::Blast::FractureTool -, Nv::Blast::FractureToolImpl +: Nv::Blast::FractureToolImpl +, Nv::Blast::FractureTool
  • setState() -: Nv::Blast::DummyAccelerator -, Nv::Blast::SpatialAccelerator -, Nv::Blast::BBoxBasedAccelerator +: Nv::Blast::SpatialAccelerator +, Nv::Blast::DummyAccelerator , Nv::Blast::GridWalker -, Nv::Blast::SweepingAccelerator -, Nv::Blast::BBoxBasedAccelerator +, Nv::Blast::BBoxBasedAccelerator +, Nv::Blast::SweepingAccelerator , Nv::Blast::SpatialAccelerator -, Nv::Blast::SweepingAccelerator +, Nv::Blast::GridWalker , Nv::Blast::BBoxBasedAccelerator -, Nv::Blast::SweepingAccelerator -, Nv::Blast::DummyAccelerator -, Nv::Blast::SpatialAccelerator +, Nv::Blast::SweepingAccelerator , Nv::Blast::DummyAccelerator
  • setStencil() : Nv::Blast::VoronoiSitesGeneratorImpl @@ -292,13 +292,13 @@
  • setType() : Nv::Blast::Serialization::PxConvexMeshGeometry::PxConvexMeshGeometry::Builder
  • setUniformHealth() -: Nv::Blast::final -, Nv::Blast::ExtPxAsset +: Nv::Blast::ExtPxAsset +, Nv::Blast::final
  • setup() : Nv::Blast::ExtGroupWorkerTask
  • setValue() -: Nv::Blast::Serialization::UUID::UUID::Builder -, btVector4 +: btVector4 +, Nv::Blast::Serialization::UUID::UUID::Builder
  • setW() : Nv::Blast::Serialization::PxQuat::PxQuat::Builder
  • setWorkerCount() @@ -322,18 +322,19 @@ : Nv::Blast::SharedMemory
  • SimplexNoise() : Nv::Blast::SimplexNoise +
  • size() +: Nv::Blast::FixedPriorityQueue< Element, Comparator > +, Nv::Blast::FixedArray< T > +, btAlignedObjectArray< T >
  • Size() : VHACD::SArray< T, N >
  • size() : Nv::Blast::FixedQueue< T > -, Nv::Blast::FixedArray< T > -, btAlignedObjectArray< T > -, Nv::Blast::FixedPriorityQueue< Element, Comparator >
  • skipObject() : Nv::Blast::ExtSerialization
  • slicing() -: Nv::Blast::FractureToolImpl -, Nv::Blast::FractureTool +: Nv::Blast::FractureTool +, Nv::Blast::FractureToolImpl
  • sortToCCW() : Nv::Blast::TriangleProcessor
  • spawn() @@ -346,7 +347,8 @@
  • startProcess() : Nv::Blast::TkGroup
  • subscribe() -: Nv::Blast::ExtPxManager +: Nv::Blast::final +, Nv::Blast::ExtPxManager , Nv::Blast::ExtPxFamily , Nv::Blast::final
  • swap() @@ -354,7 +356,7 @@
  • SweepingAccelerator() : Nv::Blast::SweepingAccelerator
  • syncFamily() -: Nv::Blast::ExtSync +: Nv::Blast::ExtSync diff --git a/docs/source_docs/files/functions_func_g.html b/docs/source_docs/files/functions_func_g.html index 777c68b..d4f83a8 100755 --- a/docs/source_docs/files/functions_func_g.html +++ b/docs/source_docs/files/functions_func_g.html @@ -1175,7 +1175,7 @@ $(document).ready(function(){initNavTree('functions_func_g.html','');}); , Nv::Blast::VoronoiSitesGeneratorImpl
  • GetVoxel() -: VHACD::Volume +: VHACD::Volume
  • GetVoxels() : VHACD::VoxelSet diff --git a/docs/source_docs/files/functions_func_s.html b/docs/source_docs/files/functions_func_s.html index 70be8ae..bbb36b4 100755 --- a/docs/source_docs/files/functions_func_s.html +++ b/docs/source_docs/files/functions_func_s.html @@ -128,6 +128,10 @@ $(document).ready(function(){initNavTree('functions_func_s.html','');});
  • setAllNodesInfoFromLL() : Nv::Blast::ExtStressSolver
  • +
  • setApproximateBonding() +: Nv::Blast::FractureTool +, Nv::Blast::FractureToolImpl +
  • setArea() : Nv::Blast::Serialization::NvBlastBond::Builder
  • @@ -331,9 +335,9 @@ $(document).ready(function(){initNavTree('functions_func_s.html','');});
  • setState() : Nv::Blast::BBoxBasedAccelerator -, Nv::Blast::DummyAccelerator -, Nv::Blast::GridWalker -, Nv::Blast::SpatialAccelerator +, Nv::Blast::DummyAccelerator +, Nv::Blast::GridWalker +, Nv::Blast::SpatialAccelerator , Nv::Blast::SweepingAccelerator
  • setStencil() @@ -350,7 +354,7 @@ $(document).ready(function(){initNavTree('functions_func_s.html','');}); : Nv::Blast::Serialization::Asset::Builder
  • setSupportChunkHealths() -: Nv::Blast::Serialization::ExtPxAsset::Builder +: Nv::Blast::Serialization::ExtPxAsset::Builder
  • setTransform() : Nv::Blast::Serialization::ExtPxSubchunk::Builder @@ -410,7 +414,7 @@ $(document).ready(function(){initNavTree('functions_func_s.html','');}); : Nv::Blast::SharedBuffer< T >
  • SharedFace() -: Nv::Blast::SharedFace +: Nv::Blast::SharedFace
  • SharedMemory() : Nv::Blast::SharedMemory diff --git a/docs/source_docs/files/functions_g.html b/docs/source_docs/files/functions_g.html index 52c92be..fc4f952 100755 --- a/docs/source_docs/files/functions_g.html +++ b/docs/source_docs/files/functions_g.html @@ -1186,7 +1186,7 @@ $(document).ready(function(){initNavTree('functions_g.html','');}); : VHACD::Volume
  • GetVoxels() -: VHACD::VoxelSet +: VHACD::VoxelSet
  • getW() : btVector4 diff --git a/docs/source_docs/files/functions_s.html b/docs/source_docs/files/functions_s.html index cf02866..34ae01d 100755 --- a/docs/source_docs/files/functions_s.html +++ b/docs/source_docs/files/functions_s.html @@ -144,6 +144,10 @@ $(document).ready(function(){initNavTree('functions_s.html','');});
  • setAllNodesInfoFromLL() : Nv::Blast::ExtStressSolver
  • +
  • setApproximateBonding() +: Nv::Blast::FractureTool +, Nv::Blast::FractureToolImpl +
  • setArea() : Nv::Blast::Serialization::NvBlastBond::Builder
  • @@ -173,7 +177,7 @@ $(document).ready(function(){initNavTree('functions_s.html','');}); : Nv::Blast::ExtSerialization
  • setCentroid() -: Nv::Blast::Serialization::NvBlastBond::Builder +: Nv::Blast::Serialization::NvBlastBond::Builder , Nv::Blast::Serialization::NvBlastChunk::Builder
  • setChildIndexStop() @@ -348,9 +352,9 @@ $(document).ready(function(){initNavTree('functions_s.html','');});
  • setState() : Nv::Blast::BBoxBasedAccelerator , Nv::Blast::DummyAccelerator -, Nv::Blast::GridWalker +, Nv::Blast::GridWalker , Nv::Blast::SpatialAccelerator -, Nv::Blast::SweepingAccelerator +, Nv::Blast::SweepingAccelerator
  • setStencil() : Nv::Blast::VoronoiSitesGenerator @@ -363,10 +367,10 @@ $(document).ready(function(){initNavTree('functions_s.html','');}); : Nv::Blast::Serialization::ExtPxAsset::Builder
  • setSubtreeLeafChunkCounts() -: Nv::Blast::Serialization::Asset::Builder +: Nv::Blast::Serialization::Asset::Builder
  • setSupportChunkHealths() -: Nv::Blast::Serialization::ExtPxAsset::Builder +: Nv::Blast::Serialization::ExtPxAsset::Builder
  • setTransform() : Nv::Blast::Serialization::ExtPxSubchunk::Builder @@ -531,12 +535,12 @@ $(document).ready(function(){initNavTree('functions_s.html','');}); , Nv::Blast::ExtPxManager , Nv::Blast::ExtPxManagerImpl
  • -
  • Subtype -: Nv::Blast::TkJointUpdateEvent -
  • subtype : Nv::Blast::TkJointUpdateEvent
  • +
  • Subtype +: Nv::Blast::TkJointUpdateEvent +
  • SuperSupport : Nv::Blast::Asset::ChunkAnnotation
  • @@ -556,7 +560,7 @@ $(document).ready(function(){initNavTree('functions_s.html','');}); : Nv::Blast::SweepingAccelerator
  • syncFamily() -: Nv::Blast::ExtSync +: Nv::Blast::ExtSync
  • diff --git a/docs/source_docs/files/functions_type.html b/docs/source_docs/files/functions_type.html index 7559434..49393de 100755 --- a/docs/source_docs/files/functions_type.html +++ b/docs/source_docs/files/functions_type.html @@ -141,15 +141,15 @@ : btAlignedAllocator< T, Alignment >

    - t -

    - v -