元編程參考文件

即時輸入

8 個節點

本頁內容 8

預設錄音裝置

函數

The recording device the system uses when none is named.

簽名
預設錄音裝置() -> 文字
string DefaultRecordingDevice()

返回

裝置文字
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理

即時監聽

函數

Plays a stereo signal live for some seconds, then stops, and says how it went: how much delay it added, how busy the machine was, and whether the input ever ran dry.

簽名
即時監聽 -> 文字
    立體聲: Stereo Signal
    秒數: 數字
    塊幀數: 整數
string Listen(
    StereoSignal stereo,
    double seconds = 10,
    int blockFrames = 256)

參數

名稱型別預設值說明
立體聲Stereo Signal—What is played.
秒數數字10How long, 0 to 3600.
塊幀數整數256Frames the device renders at a time, 32 to 16384.

返回

報告文字

備註

Waits until it has finished, so a program can carry on afterwards. 0 seconds plays nothing. Use headphones when a Microphone is in it.

所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理

測量即時延遲

函數

Measures how late a live input is heard on this machine: plays clicks through the speakers, listens for them through a recording device, and times each round trip.

簽名
測量即時延遲 -> Live Latency
    裝置: 文字
    咔嗒聲次數: 整數
    塊幀數: 整數
    緩衝: 數字
LiveLatency MeasureLatency(
    string device = "",
    int clicks = 10,
    int blockFrames = 256,
    double cushion = 0.01)

參數

名稱型別預設值說明
裝置文字—A name from Recording Devices; empty for the default.
咔嗒聲次數整數10How many clicks, half a second apart, 1 to 1000.
塊幀數整數256The output's block, as Start Live Signal would use it.
緩衝數字0.01Microphone's cushion, as a live signal would use it.

返回

延遲Live Latency

備註

The round trip is the delay between speaking into a Microphone and hearing it from Start Live Signal, plus the air between speaker and microphone. Hold the microphone near the speakers, or a headphone against it, and keep the room quiet; the median and range are of the clicks heard back.

所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理

麥克風

函數

What a recording device hears, as a signal: wire it through effects and into Start Live Signal to hear yourself through them as you speak or play.

簽名
麥克風(裝置: 文字, 緩衝: 數字) -> Signal
Signal Microphone(string device = "", double cushion = 0.01)

參數

名稱型別預設值說明
裝置文字—A name from Recording Devices; empty for the default.
緩衝數字0.01Seconds kept waiting, 0 to 0.5.

返回

訊號Signal

備註

Silent until a live session opens the device, so a chain rendered offline hears nothing from it. Cushion is the sound kept waiting so the device never runs dry between its chunks: lower is heard sooner, higher survives a busier machine.

所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理

錄音裝置

函數

The recording devices on this machine, by name: a built-in microphone, a headset, an audio interface's inputs. Any of these names goes in Microphone's Device.

簽名
錄音裝置() -> 文字陣列
string[] RecordingDevices()

返回

裝置文字陣列
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理

開始即時訊號

函數

Plays a signal live on the audio device, opening the recording device of every Microphone in it, until Stop Live Signal.

簽名
開始即時訊號 -> Live Signal Session
    訊號: Signal
    塊幀數: 整數
    錄製: 真否
    取樣率: 整數
LiveSignalSession Start(
    Signal signal,
    int blockFrames = 256,
    bool record = false,
    int sampleRate = 44100)

參數

名稱型別預設值說明
訊號Signal—What is played, on both sides.
塊幀數整數256Frames the device renders at a time, 32 to 16384; 256 is 5.8 ms at 44.1 kHz, and the device is asked for a buffer the same size. Raise it if the sound breaks up.
錄製真否FalseWhether to keep what is played, for Stop Live Signal to hand back.
取樣率整數44100The rate to run at.

返回

會話Live Signal Session

備註

Use headphones when a Microphone is in it: through speakers, the microphone hears its own sound come back and howls.

所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理

開始即時立體聲

函數

Plays a stereo signal live on the audio device - a panned voice, a stereo reverb or chorus - until Stop Live Signal.

簽名
開始即時立體聲 -> Live Signal Session
    立體聲: Stereo Signal
    塊幀數: 整數
    錄製: 真否
    取樣率: 整數
LiveSignalSession StartStereo(
    StereoSignal stereo,
    int blockFrames = 256,
    bool record = false,
    int sampleRate = 44100)

參數

名稱型別預設值說明
立體聲Stereo Signal—What is played.
塊幀數整數256Frames the device renders at a time, 32 to 16384.
錄製真否FalseWhether to keep what is played, for Stop Live Signal to hand back.
取樣率整數44100The rate to run at.

返回

會話Live Signal Session
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理

停止即時訊號

函數

Stops a live signal and closes its devices.

簽名
停止即時訊號(會話: Live Signal Session) -> AudioBuffer
AudioBuffer Stop(LiveSignalSession session)

參數

名稱型別預設值說明
會話Live Signal Session—The session.

返回

音訊AudioBuffer
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
即時輸入
所屬包
音訊處理