logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Struct FeedbackIntensity

    Immutable description of a single feedback impulse: the low- and high-frequency motor amplitudes (0..1) and how long the impulse should last, in seconds.

    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetType()
    Namespace: Serenity.Feedback.Domain.ValueObjects
    Assembly: Serenity.Feedback.Domain.dll
    Syntax
    public readonly struct FeedbackIntensity

    Constructors

    FeedbackIntensity(float, float, float)

    Initializes a new instance of the FeedbackIntensity struct.

    Declaration
    public FeedbackIntensity(float low, float high, float duration)
    Parameters
    Type Name Description
    float low

    Low-frequency motor amplitude (0..1).

    float high

    High-frequency motor amplitude (0..1).

    float duration

    Duration of the impulse in seconds.

    Fields

    Duration

    Declaration
    public readonly float Duration
    Field Value
    Type Description
    float

    Duration of the impulse in seconds. Non-negative.

    High

    Declaration
    public readonly float High
    Field Value
    Type Description
    float

    High-frequency motor amplitude, expected in the 0..1 range.

    Low

    Declaration
    public readonly float Low
    Field Value
    Type Description
    float

    Low-frequency motor amplitude, expected in the 0..1 range.

    Properties

    IsSilent

    True when both motor amplitudes are at or below zero.

    Declaration
    public bool IsSilent { get; }
    Property Value
    Type Description
    bool

    Methods

    Clamped()

    Returns a copy with amplitudes clamped to 0..1 and duration clamped to non-negative.

    Declaration
    public FeedbackIntensity Clamped()
    Returns
    Type Description
    FeedbackIntensity

    A clamped FeedbackIntensity.

    ToString()

    Returns a string representation of the intensity.

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    Formatted string with the amplitudes and duration.

    Overrides
    ValueType.ToString()
    In this article
    © 2026 Serenity. All Rights Reserved