unreal.PixelStreamingAudioComponent

class unreal.PixelStreamingAudioComponent(outer=None, name='None')

Bases: unreal.SynthComponent

Allows in-engine playback of incoming WebRTC audio from a particular Pixel Streaming player/peer using their mic in the browser. Note: Each audio component associates itself with a particular Pixel Streaming player/peer (using the the Pixel Streaming player id).

C++ Source:

  • Plugin: PixelStreaming

  • Module: PixelStreaming

  • File: PixelStreamingAudioComponent.h

Editor Properties: (see get_editor_property/set_editor_property)

  • absolute_location (bool): [Read-Write] Absolute Location: If RelativeLocation should be considered relative to the world, rather than the parent

  • absolute_rotation (bool): [Read-Write] Absolute Rotation: If RelativeRotation should be considered relative to the world, rather than the parent

  • absolute_scale (bool): [Read-Write] Absolute Scale: If RelativeScale3D should be considered relative to the world, rather than the parent

  • allow_spatialization (bool): [Read-Write] Allow Spatialization: Is this audio component allowed to be spatialized?

  • asset_user_data (Array(AssetUserData)): [Read-Write] Asset User Data: Array of user data stored with the component

  • attenuation_overrides (SoundAttenuationSettings): [Read-Write] Attenuation Overrides: If bOverrideSettings is true, the attenuation properties to use for sounds generated by this component

  • attenuation_settings (SoundAttenuation): [Read-Write] Attenuation Settings: If bOverrideSettings is false, the asset to use to determine attenuation properties for sounds generated by this component

  • auto_activate (bool): [Read-Write] Auto Activate: Whether the component is activated at creation or must be explicitly activated.

  • auto_find_peer (bool): [Read-Write] Auto Find Peer: If not already listening to a player/peer will try to attach for listening to the “PlayerToHear” each tick.

  • bus_sends (Array(SoundSourceBusSendInfo)): [Read-Write] Bus Sends: This sound will send its audio output to this list of buses if there are bus instances playing after source effects are processed.

  • can_ever_affect_navigation (bool): [Read-Write] Can Ever Affect Navigation: Whether this component can potentially influence navigation

  • component_tags (Array(Name)): [Read-Write] Component Tags: Array of tags that can be used for grouping and categorizing. Can also be accessed from scripting.

  • concurrency_set (Set(SoundConcurrency)): [Read-Write] Concurrency Set: What sound concurrency to use for sounds generated by this audio component

  • detail_mode (DetailMode): [Read-Write] Detail Mode: If detail mode is >= system detail mode, primitive won’t be rendered.

  • editable_when_inherited (bool): [Read-Write] Editable when Inherited: True if this component can be modified when it was inherited from a parent actor class

  • enable_base_submix (bool): [Read-Write] Enable Base Submix: If enabled, sound will route to the Master Submix by default or to the Base Submix if defined. If disabled, sound will route ONLY to the Submix Sends and/or Bus Sends

  • enable_bus_sends (bool): [Read-Write] Enable Bus Sends: Whether or not to enable sending this audio’s output to buses.

  • enable_submix_sends (bool): [Read-Write] Enable Submix Sends: Whether or not to enable Submix Sends other than the Base Submix.

  • envelope_follower_attack_time (int32): [Read-Write] Envelope Follower Attack Time: The attack time in milliseconds for the envelope follower. Delegate callbacks can be registered to get the envelope value of sounds played with this audio component. Only used in audio mixer.

  • envelope_follower_release_time (int32): [Read-Write] Envelope Follower Release Time: The release time in milliseconds for the envelope follower. Delegate callbacks can be registered to get the envelope value of sounds played with this audio component. Only used in audio mixer.

  • hidden_in_game (bool): [Read-Write] Hidden in Game: Whether to hide the primitive in game, if the primitive is Visible.

  • is_editor_only (bool): [Read-Write] Is Editor Only: If true, the component will be excluded from non-editor builds

  • is_ui_sound (bool): [Read-Write] Is UISound: Whether or not this sound plays when the game is paused in the UI

  • mobility (ComponentMobility): [Read-Write] Mobility: How often this component is allowed to move, used to make various optimizations. Only safe to set in constructor.

  • on_audio_envelope_value (OnSynthEnvelopeValue): [Read-Write] On Audio Envelope Value

  • on_component_activated (ActorComponentActivatedSignature): [Read-Write] On Component Activated: Called when the component has been activated, with parameter indicating if it was from a reset

  • on_component_deactivated (ActorComponentDeactivateSignature): [Read-Write] On Component Deactivated: Called when the component has been deactivated

  • override_attenuation (bool): [Read-Write] Override Attenuation: Should the Attenuation Settings asset be used (false) or should the properties set directly on the component be used for attenuation properties

  • physics_volume_changed_delegate (PhysicsVolumeChanged): [Read-Write] Physics Volume Changed Delegate: Delegate that will be called when PhysicsVolume has been changed *

  • player_to_hear (str): [Read-Write] Player to Hear: The Pixel Streaming player/peer whose audio we wish to listen to. If this is left blank this component will listen to the first non-listened to peer that connects after this component is ready. Note: that when the listened to peer disconnects this component is reset to blank and will once again listen to the next non-listened to peer that connects.

  • pre_effect_bus_sends (Array(SoundSourceBusSendInfo)): [Read-Write] Pre Effect Bus Sends: This sound will send its audio output to this list of buses if there are bus instances playing before source effects are processed.

  • primary_component_tick (ActorComponentTickFunction): [Read-Write] Primary Component Tick: Main tick function for the Component

  • relative_location (Vector): [Read-Write] Relative Location: Location of the component relative to its parent

  • relative_rotation (Rotator): [Read-Write] Relative Rotation: Rotation of the component relative to its parent

  • relative_scale3d (Vector): [Read-Write] Relative Scale 3D: Non-uniform scaling of the component relative to its parent. Note that scaling is always applied in local space (no shearing etc)

  • replicates (bool): [Read-Write] Replicates: Is this component currently replicating? Should the network code consider it for replication? Owning Actor must be replicating first!

  • should_update_physics_volume (bool): [Read-Write] Should Update Physics Volume: Whether or not the cached PhysicsVolume this component overlaps should be updated when the component is moved. see: GetPhysicsVolume()

  • sound_class (SoundClass): [Read-Write] Sound Class: Sound class this sound belongs to

  • sound_submix (SoundSubmixBase): [Read-Write] Sound Submix: Submix this sound belongs to

  • sound_submix_sends (Array(SoundSubmixSendInfo)): [Read-Write] Sound Submix Sends: An array of submix sends. Audio from this sound will send a portion of its audio to these effects.

  • source_effect_chain (SoundEffectSourcePresetChain): [Read-Write] Source Effect Chain: The source effect chain to use for this sound.

  • use_attach_parent_bound (bool): [Read-Write] Use Attach Parent Bound: If true, this component uses its parents bounds when attached. This can be a significant optimization with many components attached together.

  • visible (bool): [Read-Write] Visible: Whether to completely draw the primitive; if false, the primitive is not drawn, does not cast a shadow.

property auto_find_peer

[Read-Write] Auto Find Peer: If not already listening to a player/peer will try to attach for listening to the “PlayerToHear” each tick.

Type

(bool)

is_listening_to_player() bool

True if listening to a connected WebRTC peer through Pixel Streaming.

Return type

bool

listen_to(player_to_listen_to) bool

Listen to a specific player. If the player is not found this component will be silent.

Parameters

player_to_listen_to (str) –

Return type

bool

property player_to_hear

[Read-Write] Player to Hear: The Pixel Streaming player/peer whose audio we wish to listen to. If this is left blank this component will listen to the first non-listened to peer that connects after this component is ready. Note: that when the listened to peer disconnects this component is reset to blank and will once again listen to the next non-listened to peer that connects.

Type

(str)

reset() None

Stops listening to any connected player/peer and resets internal state so component is ready to listen again.