Example ====== Inhibit selected fixtures dimmer ====== ^ by: | Sebastian Beutel, with help by Gregory Haynes | ^ published: | here, October 2022 | ^ description: | inhibits selected fixtures: sets them @0% and freezes | ^ remarks: | idea by John Richardson, see https://www.facebook.com/groups/Avolites/posts/2641102656021952/ | See [[macros:example:inhibitselectedfixtures|]] - that freezes the entire fixtures while here we freeze only the dimmer attribute. {{tag>inhibit set dimmer selected freeze clear}} > The inhibit is just a quick way of dousing a lamp or lamps and then reinstating them without affecting anything in the programmer or within any cues. So I may be running an effect on some lamps and I just need to kill it for a second and then turn it back on without messing about with the programmer or cues. The 'without messing with the programmer' part isn't possible: you need to select the fixtures which you want to inhibit before calling the macro -- and selecting fixtures brings them into the programmer. There is no way to avoid this. ==== functions ==== * [[:macros:function:Programmer.Editor.Fixtures.IncrementDimmer]] * [[:macros:function:Programmer.Editor.Fixtures.SetContextAttributeFromId]] * [[:macros:function:Programmer.Editor.Fixtures.SetSelectedControlsFrozen]] * [[:macros:function:Programmer.Editor.ClearAll]] ===== Code ===== Inhibit On. Programmer.Editor.Fixtures.IncrementDimmer(-10000, 1.0, true) Programmer.Editor.Fixtures.SetContextAttributeFromId(16) Programmer.Editor.Fixtures.SetSelectedControlsFrozen(true) Programmer.Editor.ClearAll(false, false) Inhibit Off Programmer.Editor.Fixtures.SetContextAttributeFromId(16) Programmer.Editor.Fixtures.SetSelectedControlsFrozen(false) Programmer.Editor.ClearAll(false, false) ===== Explanation ===== This explains the functional steps within the sequence. For all the other XML details please refer to [[:macros:formats_and_syntax#xml_format|Formats and syntax]] The first macro ''Inhibit Selected Fixtures Dimmer'' sets the currently selected fixtures' dimmer at 0% and freezes them: * ''Programmer.Editor.Fixtures.IncrementDimmer(-10000, 1.0, true)'' sets the dimmer at 0 * ''Programmer.Editor.Fixtures.SetContextAttributeFromId(16)'' makes sure we are dealing with the dimmer attribute in the next step * ''Programmer.Editor.Fixtures.SetSelectedControlsFrozen(true)'' freezes the dimmer of the currently selected fixtures * ''Programmer.Editor.ClearAll(false, false)'' clears the programmer The second macro ''Uninhibit Selected Fixtures Dimmer'' unfreezes the currently selected fixtures: * ''Programmer.Editor.Fixtures.SetContextAttributeFromId(16)'' makes sure we are dealing with the dimmer attribute in the next step * ''Programmer.Editor.Fixtures.SetSelectedControlsFrozen(false)'' unfreezes the dimmer of the currently selected fixtures * ''Programmer.Editor.ClearAll(false, false)'' clears the programmer ===== How to use it ===== - [[:macros:deploying|make this macro available]] - in order to inhibit fixtures select them and fire the first macro - in order to uninhibit fixtures select them and fire the second macro ~~DISCUSSION~~