File tree Expand file tree Collapse file tree
com.unity.robotics.vhacd/Runtime Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,17 +18,18 @@ public enum FillMode
1818 }
1919
2020 [ Serializable ]
21+ [ StructLayout ( LayoutKind . Sequential ) ]
2122 public unsafe struct Parameters
2223 {
2324 public void Init ( )
2425 {
2526 m_callback = null ;
2627 m_logger = null ;
2728 m_taskRunner = null ;
28- m_maxConvexHulls = 32 ; // Performance sensitive: adding more MeshColliders slows down Unity at runtime.
29- m_resolution = 100000 ; // Higher value increases generation time.
30- m_minimumVolumePercentErrorAllowed = 1 ; // Lower value increases generation time.
31- m_maxRecursionDepth = 10 ; // Higher value increases generation time.
29+ m_maxConvexHulls = 32 ;
30+ m_resolution = 100000 ;
31+ m_minimumVolumePercentErrorAllowed = 1 ;
32+ m_maxRecursionDepth = 10 ;
3233 m_shrinkWrap = true ;
3334 m_fillMode = FillMode . FLOOD_FILL ;
3435 m_maxNumVerticesPerCH = 64 ;
@@ -41,7 +42,7 @@ public void Init()
4142 public void * m_logger ;
4243 public void * m_taskRunner ;
4344
44- [ Tooltip ( "The maximum number of convex hulls to produce. Performance sensitive." ) ]
45+ [ Tooltip ( "The maximum number of convex hulls to produce. Performance sensitive: adding more MeshColliders slows down Unity at runtime ." ) ]
4546 [ Range ( 1 , 2048 ) ]
4647 public uint m_maxConvexHulls ;
4748
@@ -80,6 +81,7 @@ public void Init()
8081 public bool m_findBestPlane ;
8182 }
8283
84+ [ StructLayout ( LayoutKind . Sequential ) ]
8385 unsafe struct ConvexHull
8486 {
8587 public double * m_points ;
Original file line number Diff line number Diff line change @@ -32,4 +32,4 @@ include_directories(${CMAKE_SOURCE_DIR}/VHACD_Lib)
3232add_library (libvhacd SHARED ${CMAKE_SOURCE_DIR} /dll/dll.cpp )
3333
3434# VHACD.h is a header-only library. Implementation needs this define flag.
35- target_compile_definitions (libvhacd PRIVATE ENABLE_VHACD_IMPLEMENTATION=1 )
35+ target_compile_definitions (libvhacd PRIVATE ENABLE_VHACD_IMPLEMENTATION=1 )
You can’t perform that action at this time.
0 commit comments