docs.unity.cn
    Show / Hide Table of Contents

    Struct PhysicsGraphicalSmoothing

    A component to indicate that the graphical representation of a dynamic rigid body's motion should be smoothed when the rendering framerate is greater than the fixed step rate used by physics. When used on its own, it indicates that smoothing should extrapolate into the future based on the body's current velocity. The result is thus up-to-date, but can mis-predict the body's transformations since any future collision response has not yet been resolved. See also PhysicsGraphicalInterpolationBuffer.

    Inherited Members
    ValueType.Equals(Object)
    ValueType.GetHashCode()
    ValueType.ToString()
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Namespace: Unity.Physics.GraphicsIntegration
    Syntax
    [WriteGroup(typeof(LocalToWorld))]
    public struct PhysicsGraphicalSmoothing : IComponentData, IQueryTypeParameter

    Fields

    ApplySmoothing

    If non-zero, apply smoothing. Set this value to 0 when teleporting a body to prevent smoothing the motion of its graphics representation. SmoothRigidBodiesGraphicalMotion will reset this value to 1 each frame.

    Declaration
    public byte ApplySmoothing
    Field Value
    Type Description
    Byte

    CurrentVelocity

    The body's linear and angular velocity from the most recent physics tick.

    Declaration
    public PhysicsVelocity CurrentVelocity
    Field Value
    Type Description
    PhysicsVelocity
    Back to top Copyright © 2023 Unity Technologies — Terms of use
    Generated by DocFX
    on Wednesday, June 21, 2023