//
// Generated by Brutal.Jolt.Generate; do not edit by hand.
#nullable enable
using Brutal.Interop;
using Brutal.Numerics;
namespace Brutal.JoltApi
{
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:40
///
/// class ContactSettings
///
///
///
///
/// When a contact point is added or persisted, the callback gets a chance to override certain properties of the contact constraint.
/// The values are filled in with their defaults by the system so the callback doesn't need to modify anything, but it can if it wants to.
///
///
[InteropHandle]
public readonly partial struct ContactSettings : IDisposable
{
public static ContactSettings Create() => Jolt.PInvoke.ContactSettings_Create();
///
///
/// Combined friction for the body pair (see: PhysicsSystem::SetCombineFriction)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:43
///
/// float mCombinedFriction
///
///
public float GetCombinedFriction() => Jolt.PInvoke.ContactSettings_GetCombinedFriction(this);
///
///
/// Combined friction for the body pair (see: PhysicsSystem::SetCombineFriction)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:43
///
/// float mCombinedFriction
///
///
public void SetCombinedFriction(float value) => Jolt.PInvoke.ContactSettings_SetCombinedFriction(this, value);
///
///
/// Combined restitution for the body pair (see: PhysicsSystem::SetCombineRestitution)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:44
///
/// float mCombinedRestitution
///
///
public float GetCombinedRestitution() => Jolt.PInvoke.ContactSettings_GetCombinedRestitution(this);
///
///
/// Combined restitution for the body pair (see: PhysicsSystem::SetCombineRestitution)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:44
///
/// float mCombinedRestitution
///
///
public void SetCombinedRestitution(float value) => Jolt.PInvoke.ContactSettings_SetCombinedRestitution(this, value);
///
///
/// Scale factor for the inverse mass of body 1 (0 = infinite mass, 1 = use original mass, 2 = body has half
/// the mass). For the same contact pair, you should strive to keep the value the same over time.
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:45
///
/// float mInvMassScale1 = 1.0f
///
///
public float GetInvMassScale1() => Jolt.PInvoke.ContactSettings_GetInvMassScale1(this);
///
///
/// Scale factor for the inverse mass of body 1 (0 = infinite mass, 1 = use original mass, 2 = body has half
/// the mass). For the same contact pair, you should strive to keep the value the same over time.
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:45
///
/// float mInvMassScale1 = 1.0f
///
///
public void SetInvMassScale1(float value) => Jolt.PInvoke.ContactSettings_SetInvMassScale1(this, value);
///
///
/// Scale factor for the inverse inertia of body 1 (usually same as mInvMassScale1)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:46
///
/// float mInvInertiaScale1 = 1.0f
///
///
public float GetInvInertiaScale1() => Jolt.PInvoke.ContactSettings_GetInvInertiaScale1(this);
///
///
/// Scale factor for the inverse inertia of body 1 (usually same as mInvMassScale1)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:46
///
/// float mInvInertiaScale1 = 1.0f
///
///
public void SetInvInertiaScale1(float value) => Jolt.PInvoke.ContactSettings_SetInvInertiaScale1(this, value);
///
///
/// Scale factor for the inverse mass of body 2 (0 = infinite mass, 1 = use original mass, 2 = body has half
/// the mass). For the same contact pair, you should strive to keep the value the same over time.
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:47
///
/// float mInvMassScale2 = 1.0f
///
///
public float GetInvMassScale2() => Jolt.PInvoke.ContactSettings_GetInvMassScale2(this);
///
///
/// Scale factor for the inverse mass of body 2 (0 = infinite mass, 1 = use original mass, 2 = body has half
/// the mass). For the same contact pair, you should strive to keep the value the same over time.
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:47
///
/// float mInvMassScale2 = 1.0f
///
///
public void SetInvMassScale2(float value) => Jolt.PInvoke.ContactSettings_SetInvMassScale2(this, value);
///
///
/// Scale factor for the inverse inertia of body 2 (usually same as mInvMassScale2)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:48
///
/// float mInvInertiaScale2 = 1.0f
///
///
public float GetInvInertiaScale2() => Jolt.PInvoke.ContactSettings_GetInvInertiaScale2(this);
///
///
/// Scale factor for the inverse inertia of body 2 (usually same as mInvMassScale2)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:48
///
/// float mInvInertiaScale2 = 1.0f
///
///
public void SetInvInertiaScale2(float value) => Jolt.PInvoke.ContactSettings_SetInvInertiaScale2(this, value);
///
///
/// If the contact should be treated as a sensor vs body contact (no collision response)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:49
///
/// bool mIsSensor
///
///
public bool GetIsSensor() => Jolt.PInvoke.ContactSettings_GetIsSensor(this);
///
///
/// If the contact should be treated as a sensor vs body contact (no collision response)
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:49
///
/// bool mIsSensor
///
///
public void SetIsSensor(bool value) => Jolt.PInvoke.ContactSettings_SetIsSensor(this, value);
///
///
/// Relative linear surface velocity between the bodies (world space surface velocity of body 2 - world
/// space surface velocity of body 1), can be used to create a conveyor belt effect
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:50
///
/// Vec3 mRelativeLinearSurfaceVelocity = Vec3::sZero()
///
///
public float3 GetRelativeLinearSurfaceVelocity() => Jolt.PInvoke.ContactSettings_GetRelativeLinearSurfaceVelocity(this);
///
///
/// Relative linear surface velocity between the bodies (world space surface velocity of body 2 - world
/// space surface velocity of body 1), can be used to create a conveyor belt effect
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:50
///
/// Vec3 mRelativeLinearSurfaceVelocity = Vec3::sZero()
///
///
public void SetRelativeLinearSurfaceVelocity(float3 value) => Jolt.PInvoke.ContactSettings_SetRelativeLinearSurfaceVelocity(this, value);
///
///
/// Relative angular surface velocity between the bodies (world space angular surface velocity of body 2 -
/// world space angular surface velocity of body 1). Note that this angular velocity is relative to the
/// center of mass of body 1, so if you want it relative to body 2's center of mass you need to add body 2
/// angular velocity x (body 1 world space center of mass - body 2 world space center of mass) to
/// mRelativeLinearSurfaceVelocity.
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:51
///
/// Vec3 mRelativeAngularSurfaceVelocity = Vec3::sZero()
///
///
public float3 GetRelativeAngularSurfaceVelocity() => Jolt.PInvoke.ContactSettings_GetRelativeAngularSurfaceVelocity(this);
///
///
/// Relative angular surface velocity between the bodies (world space angular surface velocity of body 2 -
/// world space angular surface velocity of body 1). Note that this angular velocity is relative to the
/// center of mass of body 1, so if you want it relative to body 2's center of mass you need to add body 2
/// angular velocity x (body 1 world space center of mass - body 2 world space center of mass) to
/// mRelativeLinearSurfaceVelocity.
///
///
/// C++:
/// Jolt/Physics/Collision/ContactListener.h:51
///
/// Vec3 mRelativeAngularSurfaceVelocity = Vec3::sZero()
///
///
public void SetRelativeAngularSurfaceVelocity(float3 value) => Jolt.PInvoke.ContactSettings_SetRelativeAngularSurfaceVelocity(this, value);
public void Dispose() => Jolt.PInvoke.ContactSettings_Destroy(this);
}
}