AudioDeviceOutput

사용되지 않는 항목 표시

*이 콘텐츠는 AI(베타)를 사용해 번역되었으며, 오류가 있을 수 있습니다. 이 페이지를 영어로 보려면 여기를 클릭하세요.

AudioDeviceOutput 오디오 스트림을 스피커나 헤드폰과 같은 물리적 하드웨어 장치에 렌더링하도록 수락합니다.그것은 입력 핀을 제공하여 Wires.모든 오디오 스트림이 케이블로 연결된 AudioDeviceOutput에 들립니다.

코드 샘플

Outputting Audio to Device

local audioPlayer: AudioPlayer = Instance.new("AudioPlayer")
audioPlayer.Parent = workspace
audioPlayer.AssetId = "rbxassetid://9112854440"
local deviceOutput = Instance.new("AudioDeviceOutput")
deviceOutput.Parent = workspace
local wire = Instance.new("Wire")
wire.Parent = workspace
wire.SourceInstance = audioPlayer
wire.TargetInstance = deviceOutput
audioPlayer:Play()

요약

속성

이벤트

속성

Player

병렬 읽기

연결된 오디오 스트림을 듣기 위한 선택적 Player 누군가.지정되지 않으면 이 AudioDeviceOutput 에 연결된 스트림이 모두에 의해 들리게 됩니다.

메서드

GetConnectedWires

Instances

지정된 핀하다연결된 배열 Wires 을 반환합니다. AudioDeviceOutput 에는 "입력" 핀하다하나 있습니다.

매개 변수

pin: string
기본값: ""

반환

Instances

GetInputPins


반환

GetOutputPins


반환

이벤트

WiringChanged

연결되거나 연결 해제된 Wire 후 발생하는 이벤트로, Wire 는 현재 또는 이전에 AudioDeviceOutput 및 다른 연결 가능한 인스턴스에 고정되었거나 고정되었습니다.

매개 변수

connected: boolean

인스턴스가 연결되었거나 연결 해제되었는지 여부.

pin: string

타겟 AudioDeviceOutput 에 있는 핀은 다음과 같습니다.The pin on the that the Wire targets.

wire: Wire

Wire 와 다른 인스턴스 사이의 AudioDeviceOutput.

instance: Instance

Wire를 통해 연결된 다른 인스턴스.