Markers on the fly

[Updated for QLab 4.1 13 Jul 17]

Prior to QLab 4 There was no inbuilt tool to record sequences of cues in real time. The method below is for QLab 3 users. It is obsolete in QLab 4. Here is the Record Cue Sequence window accessed from the tools menu in QLab 4

 

record cue sequence

Details of how to use it are in the QLab 4 documentation online here.

 

For QLab 3 Users:

If you need to create a large number of OSC or MSC cues, (or any other cue types  for that matter), timed to specific points in an audio or video cue, this workspace might be useful.

You can play an audio or video cue, and hit a hotkey every time you want to create an OSC or MSC cue, ‘ on the fly’. When you hit the hotkey a cue is created, with a pre wait corresponding to the elapsed time of the cue you are setting your markers to. When all your cues are created, another hotkey will  group the created cues  with the media cue.

Here it is in action:

How It Works:

tell front workspace
make type “OSC”
set audiocue to first item of (active cues as list)
set thewaiter to (action elapsed of audiocue)
set currentcue to last item of (selected as list)
set q number of currentcue to “”
set pre wait of currentcue to thewaiter
set patch of currentcue to 2
set osc message type of currentcue to custom
set custom message of currentcue to “/go” –Your OSC Goes here
end tell

When the hotkey is pressed “§”  the GEN cue script is triggered.

It makes a new OSC cue and sets it’s pre wait time to the elapsed time of the running audio or video cue. it sets the properties of the OSC cue, in our example to patch 2 (it assumes 1 is used for localhost) and with an OSC custom message type. You edit this script to include the OSC custom message you want programmed where indicated.

When you have finished marking the cue points you manually select all the new OSC cues and the sound or video cue the pre waits relate to, by shift clicking. You then press “G” to trigger the Grouping.

tell front workspace
try
set thecue to first item of (selected as list)
set thegrouptitle to the q name of thecue
set thecuenumber to the q number of thecue
set the q number of thecue to “”
set thegrouptitle to thegrouptitle & “+ Timed Cues”
make type “group”
set thegroup to last item of (selected as list)
set q name of thegroup to thegrouptitle
set q number of thegroup to thecuenumber
set mode of thegroup to fire_all
end try
end tell

This script stores  the cue name and number of the sound or video cue, makes a group cue, and places all the selected cues within it, sets the mode to fire all, and gives the group cue the original number of the sound or video cue, and a name based on the original name.

You can download the workspace here

It requires QLab v 3.1.10 to function.

 

If you need to make MSC cues with specific cue numbers included, this script or a variation on it, should do what you want. Create a script cue and number it MSCG. Assign a hotkey to the script and use in the same way as the OSC example above.

 

set midipatchnumber to 1 –set patch for midi output device here
set deviceIDnumber to 0 –set device ID here

 

tell front workspace
try
make type “MIDI”
set audiocue to first item of (active cues as list)
set thewaiter to (action elapsed of audiocue)
set currentcue to last item of (selected as list)
set q number of currentcue to “”
set pre wait of currentcue to thewaiter
set patch of currentcue to midipatchnumber
set message type of currentcue to msc
set deviceID of currentcue to deviceIDnumber
set command format of currentcue to 1 –General MSC
set command number of currentcue to 1 –MSC Go
set q_number of currentcue to notes of cue “MSCG”
set notes of cue “MSCG” to (notes of cue “MSCG”) + 1
set q_list of currentcue to “1”
end try
end tell

 

Every time the script is run an MSC cue is created, in this example an MSC go with a cue number, and the cue number for the MSC is incremented by 1. Because QLab doesn’t facilitate global variables you have to find somewhere to store them. In this case we are using the notes field of the script cue. Before generating a sequence of cues, set the number in the notes field of the script cue  to the first  MSC cue number you want to generate in the sequence.

The script should be easy to adapt for other MSC messages. Script hooks you may find useful when referring to parameters in MSC cues are:

deviceID (integer) : MIDI Show Control device ID.

command format (integer) : MIDI Show Control command format.

command number (integer) : MIDI Show Control command.

q_number (text) : Q Number message parameter.

q_list (text) : Q List message parameter.

q_path (text) : Q Path message parameter.

macro (integer) : MSC macro.

control number (integer) : MSC control number.

control value (integer) : MSC control value.

 

Fly Picture By JJ Harrison (jjharrison89@facebook.com) (Own work) CC BY-SA 1.0 (http://creativecommons.org/licenses/by-sa/1.0)%5D, via Wikimedia Commons.

Modified Image by Mic Pool distributed under the same license.

Music in demo video by Rameau. (Public Domain) Arrangement and recording ©Mic Pool 2014

MenuGraphic