macros:example:createdummypalettes
Table of Contents
Example
Create Dummy Palettes
by: | Sebastian Beutel |
---|---|
published: | August 2023 |
description: | idea: Discord, @TEMO patch a dummy fixture, create colour palettes, remove dummy fixture This is a really huge macro which documents a lot of programming techniques, e.g. patching a fixture, setting values in the programmer, creating palettes, storing cues and cuelists |
remarks: | start a new show and fire this macro. It will create global colour palettes for you. |
This was the plan:
What needs to be done :
- Unpack Macro needs to create the Dummy palettes 1 through 10, 11 through 20
- Unpack Macro needs to create the Bump Palletes 101 & 102
- Unpack Macro needs to create Playbacks( 11 thro 20, 21 thro 30, 31 thro 40 & Cuelists ( 101 thro 110 ) for the Macros
- Unpack Macro needs to Link Macros to Cues in Playlist
- Unpack Macro needs to record the Playback Groups for the Bump Selection
- Unpack Macro needs to create a Layout View and move the Selection Cue Lists to the Colour picker
- Layout at position X & Y
- Unpack Macro needs to add the Colour Selection Button Macros to the layout view
The macro shown here does the first half of the tasks.
functions
affected properties
control structures
Full file here: createdummypalettes.xml
Code
- createDummyPalettesShort.xml
- <?xml version="1.0" encoding="utf-8"?>
- <avolites.macros>
- <!-- at first some dummy macros, to check the linking in the cuelists -->
- <macro id="Wiki.Macros.Dummy.001" name="Dummy Macro 001">
- <description>Dummy Macro 001</description>
- <sequence>
- </sequence>
- </macro>
- <!-- more dummy macros... -->
- <macro id="Wiki.Macros.Dummy.010" name="Dummy Macro 010">
- <description>Dummy Macro 010</description>
- <sequence>
- </sequence>
- </macro>
- <!-- the heavy lifting -->
- <macro id="Wiki.Macros.Palette.CreateDummy.001" name="Create Dummy Palettes v.001">
- <sequence>
- <!-- patch an RGB fixture -->
- <step>ActionScript.SetProperty("Patch.CurrentUserNumber", userNumber:999)</step>
- <step>Fixtures.PatchFixturesToVacantHandles("Fixtures", "Expolite", "TourLED 42 CM MKII", "ARC.1, 3 DMX", 1, 3, "")</step>
- <step>Handles.SetSourceHandleFromHandle("fixtureHandleUN=999")</step>
- <step>ActionScript.SetProperty.Enum("Handles.OperationMode", "move")</step>
- <step>Handles.CopyDestination("Fixtures", 99)</step>
- <step>Handles.ClearSelection()</step>
- <!-- select fixture -->
- <step pause="0.1">Programmer.Editor.Selection.SelectFixture(handle:"fixtureHandleUN=999")</step>
- <!-- set some colour values and quick-create palettes -->
- <step>Programmer.Editor.Fixtures.SetControlValueById(240, 1, 1.0, true, true)</step>
- <step>Programmer.Editor.Fixtures.SetControlValueById(256, 1, 0.6, true, true)</step>
- <step>Programmer.Editor.Fixtures.SetControlValueById(272, 1, 0.2, true, true)</step>
- <step pause="0.1">Palette.QuickCreatePalette(Handles.CreateHandleReference("Colours", 0, 0), "C", userNumber:101, "", 0)</step>
- <!-- create some more palettes... -->
- <step>Programmer.Editor.Fixtures.SetControlValueById(240, 1, 0.3, true, true)</step>
- <step>Programmer.Editor.Fixtures.SetControlValueById(256, 1, 0.6, true, true)</step>
- <step>Programmer.Editor.Fixtures.SetControlValueById(272, 1, 1.0, true, true)</step>
- <step pause="0.1">Palette.QuickCreatePalette(Handles.CreateHandleReference("Colours", 0, 4), "C", userNumber:105, "", 0)</step>
- <!-- clear programmer -->
- <step>Programmer.Editor.ClearAll(false, false)</step>
- <!-- create abstract palettes -->
- <step pause="0.1">Programmer.Editor.Selection.SelectFixture(handle:"fixtureHandleUN=999")</step>
- <step pause="0.1">Palette.ApplyPalette("Location=Colours,0,0", false)</step>
- <step pause="0.1">Palette.QuickCreatePalette(Handles.CreateHandleReference("Colours", 0, 15), "C", userNumber:201, "Foreground", 0)</step>
- <step pause="0.1">Palette.QuickCreatePalette(Handles.CreateHandleReference("Colours", 0, 16), "C", userNumber:202, "Background", 0)</step>
- <step pause="0.1">Programmer.Editor.ClearAll(false, false)</step>
- <!-- create Playbacks (11~20, 21~30, 31~40) & Cuelists (101~110) -->
- <step pause="0.1">Playbacks.StoreCue("PlaybackWindow", 211, true)</step>
- <step>Handles.SetSourceHandle("PlaybackWindow", 211)</step>
- <step>ActionScript.SetProperty("Handles.CurrentUserNumber", userNumber:11)</step>
- <step>Handles.SetUserNumber()</step>
- <step>Handles.ClearSelection()</step>
- <!-- create some more cue playbacks here... -->
- <step pause="0.1">Playbacks.StoreCue("PlaybackWindow", 240, true)</step>
- <step>Handles.SetSourceHandle("PlaybackWindow", 240)</step<
- <step>ActionScript.SetProperty("Handles.CurrentUserNumber", userNumber:40)</step>
- <step>Handles.SetUserNumber()</step>
- <step>Handles.ClearSelection()</step>
- <!-- Cuelists -->
- <step pause="0.1">Playbacks.CueList.CreateCueList("PlaybackWindow", 101)</step>
- <step>Handles.SetSourceHandle("PlaybackWindow", 101)</step>
- <step>ActionScript.SetProperty("Handles.CurrentUserNumber", userNumber:101)</step>
- <step>Handles.SetUserNumber()</step>
- <step>Handles.ClearSelection()</step>
- <step>Playbacks.Select.EditHandle("cueListHandleUN=101")</step>
- <step>Playbacks.AppendOrInsertPlaybackStep(Playbacks.PlaybackEdit.Handle,1)</step>
- <step>Playbacks.Editor.CueSelection.SelectCueByNumber(Playbacks.PlaybackEdit.Handle, 1)</step>
- <step>Playbacks.Editor.Macros.AddLinkFromId("Wiki.Macros.Dummy.001")</step>
- <step>Playbacks.PlaybackEdit.Exit()</step>
- <!-- create some more cuelists here... -->
- <step pause="0.1">Playbacks.CueList.CreateCueList("PlaybackWindow", 110)</step>
- <step>Handles.SetSourceHandle("PlaybackWindow", 110)</step>
- <step>ActionScript.SetProperty("Handles.CurrentUserNumber", userNumber:110)</step>
- <step>Handles.SetUserNumber()</step>
- <step>Handles.ClearSelection()</step>
- <step>Playbacks.Select.EditHandle("cueListHandleUN=110")</step>
- <step>Playbacks.AppendOrInsertPlaybackStep(Playbacks.PlaybackEdit.Handle,1)</step>
- <step>Playbacks.Editor.CueSelection.SelectCueByNumber(Playbacks.PlaybackEdit.Handle, 1)</step>
- <step>Playbacks.Editor.Macros.AddLinkFromId("Wiki.Macros.Dummy.010")</step>
- <step>Playbacks.PlaybackEdit.Exit()</step>
- <!-- unassign dummy fixture -->
- <step pause="0.2">ActionScript.SetProperty.Boolean("Handles.AllowDeleteFixtures", true)</step>
- <step>Handles.SetSourceHandleFromHandle("fixtureHandleUN=999")</step>
- <step>Handles.ConfirmRelease()</step> <!-- in order to delete use Handles.ConfirmDelete() -->
- <step>ActionScript.SetProperty.Boolean("Handles.AllowDeleteFixtures", false)</step>
- <!-- open Colours and Playbacks workspace windows -->
- <step><menuLink id="Windows.Playbacks" stack="mainWindowStack" behaviour="PushOrRaise" /></step>
- <step><menuLink id="Windows.Colours" stack="mainWindowStack" behaviour="PushOrRaise" /></step>
- </sequence>
- </macro>
- </avolites.macros>
Explanation
This explains the functional steps within the sequence. For all the other XML details please refer to Formats and syntax
tbd
How to use it
You could leave a comment if you were logged in.
macros/example/createdummypalettes.txt · Last modified: 2024/08/09 21:25 by 127.0.0.1