From 4bced2d73f61b440f81b3dff68e66cad5787d64d Mon Sep 17 00:00:00 2001 From: "WISH\\AndyBuchanan" Date: Tue, 14 Aug 2018 16:06:02 +0100 Subject: Fixes to UnitySample to make it build & run. ( In Unity 2018.2 ) --- .../Assets/Plugins/Blast/NvBlastWrapper.cs | 135 ++++++++++++--------- 1 file changed, 77 insertions(+), 58 deletions(-) (limited to 'examples/UnityExample/Assets/Plugins/Blast/NvBlastWrapper.cs') diff --git a/examples/UnityExample/Assets/Plugins/Blast/NvBlastWrapper.cs b/examples/UnityExample/Assets/Plugins/Blast/NvBlastWrapper.cs index 13822f8..41b4f68 100755 --- a/examples/UnityExample/Assets/Plugins/Blast/NvBlastWrapper.cs +++ b/examples/UnityExample/Assets/Plugins/Blast/NvBlastWrapper.cs @@ -13,8 +13,8 @@ public struct NvBlastChunkDesc SupportFlag = (1 << 0) }; - /** Central position in chunk. */ - public Single c0; + /** Central position in chunk. */ + public Single c0; public Single c1; public Single c2; @@ -49,12 +49,12 @@ public struct NvBlastBond public struct NvBlastBondDesc { - /** The indices of the chunks linked by this bond. They must be different support chunk indices. */ - public UInt32 chunk0; - public UInt32 chunk1; + /** Bond data (see NvBlastBond). */ + public NvBlastBond bond; - /** Bond data (see NvBlastBond). */ - public NvBlastBond bond; + /** The indices of the chunks linked by this bond. They must be different support chunk indices. */ + public UInt32 chunk0; + public UInt32 chunk1; } [StructLayout(LayoutKind.Sequential)] @@ -137,7 +137,8 @@ public struct NvBlastChunk public UInt32 userData; }; -public struct NvBlastChunkGraph + +public struct NvBlastSupportGraph { UInt32 nodeCount; public IntPtr chunkIndices; @@ -189,28 +190,34 @@ public class NvBlastFractureBuffers public class NvBlastActorSplitEvent { public IntPtr deletedActor; //!< deleted actor or nullptr if actor has not changed - public IntPtr newActors; //!< list of created actors + public IntPtr newActors; //!< list of created actors ( NvBlastActor** ) }; [StructLayout(LayoutKind.Sequential)] public class NvBlastGraphShaderActor { - UInt32 firstGraphNodeIndex; //