Files
Fishing2/Assets/Obi/Scripts/Common/Backends/Oni/Constraints/Volume/OniVolumeConstraintsBatchImpl.cs
2026-01-01 22:00:33 +08:00

26 lines
1.1 KiB
C#

#if (OBI_ONI_SUPPORTED)
using System;
using System.Collections;
using System.Runtime.InteropServices;
namespace Obi
{
public class OniVolumeConstraintsBatchImpl : OniConstraintsBatchImpl, IVolumeConstraintsBatchImpl
{
public OniVolumeConstraintsBatchImpl(OniVolumeConstraintsImpl constraints) : base(constraints, Oni.ConstraintType.Volume)
{
}
public void SetVolumeConstraints(ObiNativeIntList triangles,
ObiNativeIntList firstTriangle,
ObiNativeIntList numTriangles,
ObiNativeFloatList restVolumes,
ObiNativeVector2List pressureStiffness,
ObiNativeFloatList lambdas,
int count)
{
Oni.SetVolumeConstraints(oniBatch, triangles.GetIntPtr(), firstTriangle.GetIntPtr(), numTriangles.GetIntPtr(), restVolumes.GetIntPtr(), pressureStiffness.GetIntPtr(), lambdas.GetIntPtr(), count);
}
}
}
#endif