修改水
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
#if (OBI_ONI_SUPPORTED)
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Obi
|
||||
{
|
||||
public class OniTetherConstraintsBatchImpl : OniConstraintsBatchImpl, ITetherConstraintsBatchImpl
|
||||
{
|
||||
public OniTetherConstraintsBatchImpl(OniTetherConstraintsImpl constraints) : base(constraints, Oni.ConstraintType.Tether)
|
||||
{
|
||||
}
|
||||
|
||||
public void SetTetherConstraints(ObiNativeIntList particleIndices, ObiNativeVector2List maxLengthScale, ObiNativeFloatList stiffnesses, ObiNativeFloatList lambdas, int count)
|
||||
{
|
||||
Oni.SetTetherConstraints(oniBatch, particleIndices.GetIntPtr(), maxLengthScale.GetIntPtr(), stiffnesses.GetIntPtr(), lambdas.GetIntPtr(), count);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8d972dca9090340739b46bfce8769234
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,28 @@
|
||||
#if (OBI_ONI_SUPPORTED)
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Obi
|
||||
{
|
||||
public class OniTetherConstraintsImpl : OniConstraintsImpl
|
||||
{
|
||||
|
||||
public OniTetherConstraintsImpl(OniSolverImpl solver) : base(solver, Oni.ConstraintType.Tether)
|
||||
{
|
||||
}
|
||||
|
||||
public override IConstraintsBatchImpl CreateConstraintsBatch()
|
||||
{
|
||||
var batch = new OniTetherConstraintsBatchImpl(this);
|
||||
Oni.AddBatch(((OniSolverImpl)solver).oniSolver, ((OniConstraintsBatchImpl)batch).oniBatch);
|
||||
return batch;
|
||||
}
|
||||
|
||||
public override void RemoveBatch(IConstraintsBatchImpl batch)
|
||||
{
|
||||
Oni.RemoveBatch(((OniSolverImpl)solver).oniSolver, ((OniConstraintsBatchImpl)batch).oniBatch);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 6922281fd02e54bc2907d3327e602daf
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user