AudioStreamPlayer3D

    Plays positional sound in 3D space.

    AudioStreamPlayer3D.swift:23
    class AudioStreamPlayer3D

    Plays audio with positional sound effects, based on the relative position of the audio listener. Positional effects include distance attenuation, directionality, and the Doppler effect. For greater realism, a low-pass filter is applied to distant sounds. This can be disabled by setting attenuationFilterCutoffHz to 20500.

    By default, audio is heard from the camera position. This can be changed by adding an AudioListener3D node to the scene and enabling it by calling makeCurrent on it.

    See also AudioStreamPlayer to play a sound non-positionally.

    This object emits the following signals:

    Superclasses

    • class Node3D

      Most basic 3D game object, parent of all 3D-related nodes.

    Citizens in SwiftGodot

    Conformances

    • protocol CustomStringConvertible

      A type with a customized textual representation.

    • protocol Equatable

      A type that can be compared for value equality.

    • protocol Hashable

      A type that can be hashed into a Hasher to produce an integer hash value.

    • protocol Identifiable<ID>

      A class of types whose instances hold the value of an entity with stable identity.

    • protocol VariantRepresentable

      Types that conform to VariantRepresentable can be stored directly in Variant with no conversion. These include all of the Variant types from Godot (for example GString, Rect, Plane), Godot objects (those that subclass SwiftGodot.Object) as well as the built-in Swift types UInt8, Int64 and Double.

    • protocol VariantStorable

      Types that conform to VariantStorable can be stored in a Variant and can be extracted back out of a Variant.

    Types

    Type members

    Instance members