SetFader(handle, {[number], [boolean], [string]})

grandMA3 ユーザマニュアル » プラグイン » Lua 関数 - Object-Free API » SetFader(handle, {[number], [boolean], [string]})
Version 2.2

説明

SetFader 関数は、フェーダを指定されたレベルに設定します。フェーダを持つオブジェクトで用いる必要があります。

引数

  • handle:
    light_userdata 型のハンドルです。オブジェクトでコロン記法を用いる場合は省略できます。
  • table:
    テーブルには、キー/値形式をで最大3つの名前付き要素を含めることができます。
    • "value":
      This is a float number indicating the fader position on a scale from 0 to 100. This should always be part of the table.
    • "token":
      This is a string indicating the fader. The string must start with "Fader". It can be omitted, and then the value will be assigned to the Master fader. The fader name must be valid for the object being used. Possible tokens include:
      • "FaderMaster"
      • "FaderX"
      • "FaderXA"
      • "FaderXB"
      • "FaderTemp"
      • "FaderRate"
      • "FaderSpeed"
      • "FaderHighlight"
      • "FaderLowlight"
      • "FaderTime"
      • "FaderSolo"
    • "faderEnabled":
      If the fader can be toggled, then this boolean can be used to enable or disable the fader. A true value sets the fader to enabled.

戻り値

この関数は何も返しません。

This example changes the selected sequences' Master fader to 100% and the Time fader to 5 seconds and enables the time fader.

Lua
return function()
-- SelectedSequence() creates a handle to the selected sequence.
local selectedSequence = SelectedSequence()
-- Set the master fader to 100. The FaderMaster is the default token, so it can be omitted.
selectedSequence:SetFader({value=100.0})
-- Set the time fader to 5 seconds and enable the fader.
selectedSequence:SetFader({value=50.0, faderEnabled=1, token="FaderTime"})
end