]> git.sesse.net Git - casparcg/blob - Casparcg 2.0 Documentation.txt
2.0.0.2: All pipeline stages share thread context. This is a better and simpler desig...
[casparcg] / Casparcg 2.0 Documentation.txt
1 ##################################################################################\r
2 CasparCG 2.0 Documentation\r
3 ##################################################################################\r
4 ==================================================================================\r
5 Document History\r
6 ==================================================================================\r
7 \r
8 Version         Date                    Description                     Author\r
9 ----------------------------------------------------------------------------------\r
10 1                       2011-05-12              Initial draft.          Robert Nagy\r
11 \r
12 ==================================================================================\r
13 1. CasparCG Server\r
14 ==================================================================================\r
15 The CasparCG 2.0 Server is based open tree components types; "producers", "mixers" and \r
16 "consumers" which in combined configurations make up a "channel". The server also\r
17 has "protocols" for communication and controlling.\r
18 \r
19         Producer - Renders and plays media such as video, animations, images and audio.\r
20         A producer listens for commands and data sent from a client controller, then \r
21         loads and renders that media and sends it to the next stage in the rendering \r
22         pipeline (the mixer).\r
23         \r
24         Consumer - Receives playing media such as video, animations, images and audio \r
25         from a producer and displays that media on a specified output, for example a \r
26         window on the computer monitor or an SDI card.\r
27 \r
28         Mixer - Composites video- and audio-streams received from producers on different \r
29         layers. Also performs various video and audio transformations on the video-streams.\r
30 \r
31         Protocol - Recevies, parses and executes commands.\r
32 \r
33 ----------------------------------------------------------------------------------\r
34 Figure 1. A simplified diagram of the CasparCG 2.0 Architecture.\r
35 ----------------------------------------------------------------------------------\r
36   |----------|     ##################\r
37   | PROTOCOL |<--- | TCP CONNECTION |\r
38   |----------|     ##################\r
39      |    ^\r
40          |    |  commands/responses\r
41          v    |\r
42   |----------| <-   empty frame   <- |----------| <-   frame format  <- |----------|\r
43   | PRODUCER |                       |   MIXER  |                       | CONSUMER |\r
44   |----------| -> rendered frames -> |----------| -> formatted frame -> |----------|\r
45            ^                            |     ^                               |\r
46            | data                       |     |                               | frame\r
47            |                            v     |                               v\r
48     ########                            #######                         ##################\r
49     | FILE |                            | GPU |                         | DISPLAY DEVICE |\r
50     ########                            #######                         ##################\r
51 \r
52 **********************************************************************************\r
53 1.1. Producers\r
54 **********************************************************************************\r
55 CasparCG 2.0 currently (fully or partially) supports the following producers:\r
56 \r
57         Name                            File Extensions                 Description\r
58         --------------------------------------------------------------------------\r
59         flash                           swf\r
60 \r
61         cg                              ft\r
62 \r
63         ct                              ct                              Plays "compressed templates"\r
64                                                                         zip file containing a \r
65                                                                         flash-template together with \r
66                                                                         required media and data xml.\r
67 \r
68         ffmpeg                          mpg, mpeg, avi, mov, qt,        Plays regular video and/or\r
69                                         webm, dv, mp4, f4v, flw, mkv,   audio\r
70                                         mka, wmv, ogg, divx, xvid, \r
71                                         wav, mp3, m2v\r
72 \r
73         image                           tga, png, bmp, jpg, jpeg, gif   Plays images.\r
74                                                 tiff\r
75 \r
76         decklink                                                        Plays input from a decklink\r
77                                                                         device.\r
78                                                                                                                 \r
79 ----------------------------------------------------------------------------------\r
80 1.2.1. Flash Producer (flash)\r
81 ----------------------------------------------------------------------------------\r
82 ----------------------------------------------------------------------------------\r
83 1.2.2. Template Graphics Producer (cg)\r
84 ----------------------------------------------------------------------------------\r
85 ----------------------------------------------------------------------------------\r
86 1.2.3. Compressed Template Graphics Producer (ct)\r
87 ----------------------------------------------------------------------------------\r
88 ----------------------------------------------------------------------------------\r
89 1.2.4. FFMPEG Producer (ffmpeg)\r
90 ----------------------------------------------------------------------------------\r
91 ----------------------------------------------------------------------------------\r
92 1.2.5. Image Producer (image)\r
93 ----------------------------------------------------------------------------------\r
94 ----------------------------------------------------------------------------------\r
95 1.2.5. Decklink Producer (decklink)\r
96 ----------------------------------------------------------------------------------\r
97 \r
98 **********************************************************************************\r
99 1.2. Consumers\r
100 **********************************************************************************\r
101 CasparCG 2.0 currently (fully or partially) supports the following producers:\r
102 \r
103         Name            Description\r
104         ------------------------------------------\r
105         bluefish        Plays video and/or audio  to a bluefish-device.\r
106 \r
107         decklink        Plays video and/or audio  to a decklink-device.\r
108                 \r
109         ffmpeg          Plays video and/or audio to a file.                             \r
110                                                 \r
111         oal             Plays audio to the default system audio-device.         \r
112         \r
113         ogl             Plays video to a windowed or fullscreen window.         \r
114 \r
115 ----------------------------------------------------------------------------------\r
116 1.2.1. Bluefish Consumer (bluefish)\r
117 ----------------------------------------------------------------------------------\r
118 ----------------------------------------------------------------------------------\r
119 1.2.2. Decklink Consumer (decklink)\r
120 ----------------------------------------------------------------------------------\r
121 ----------------------------------------------------------------------------------\r
122 1.2.3. FFMPEG Consumer (ffmpeg)\r
123 ----------------------------------------------------------------------------------\r
124 ----------------------------------------------------------------------------------\r
125 1.2.4. OpenAL Consumer (openal)\r
126 ----------------------------------------------------------------------------------\r
127 ----------------------------------------------------------------------------------\r
128 1.2.5. OpenGL Consumer (opengl)\r
129 ----------------------------------------------------------------------------------\r
130                 \r
131 **********************************************************************************\r
132 1.3. Mixers\r
133 **********************************************************************************\r
134 CasparCG 2.0 currently only supports a GPU-accelerated OpenGL 3.1 mixer.        \r
135                                         \r
136 **********************************************************************************\r
137 1.3. Protocols\r
138 **********************************************************************************\r
139 \r
140 ==================================================================================\r
141 2. Advanced Media Control Protocol (AMCP) 2.0\r
142 ==================================================================================\r
143 The AMCP protocol is the main communication protocol used to control and query \r
144 CasparCG 2.0.\r
145 \r
146 - All communication is presumed to be encoded in UTF-8.\r
147 - Each command has to be terminated with both a carriage return and a linefeed \r
148 character. (\r\n, <CR><LF>, <0x0D><0x0A> or <13><10>, whichever your programming \r
149 language likes best).\r
150 - The whole command string is case insensitive.\r
151 - Since the parameters in a command is separated by spaces, you need to enclose\r
152 the parameter with quotation marks if you want it to contain spaces.\r
153 \r
154 **********************************************************************************\r
155 2.1. Backward Compatibility\r
156 **********************************************************************************\r
157 The AMCP 2.0 protocol implementation is mostly backward compatible with the \r
158 previous AMCP 1.8 and 1.7.1 protocols. This is achieved by providing default \r
159 values for parameters used by the AMCP 2.0 protocol.\r
160 \r
161 ----------------------------------------------------------------------------------\r
162 2.1.1. Breaking Changes\r
163 ----------------------------------------------------------------------------------\r
164 - CLEAR command will also clear any visible template graphic in the specified\r
165 container.\r
166 \r
167 **********************************************************************************\r
168 2.2 Special sequences\r
169 **********************************************************************************\r
170 Since bare quotation marks are used to keep parameters with spaces in one piece, \r
171 there has to be another way to indicate a quotation mark in a string. Enter special \r
172 sequences. They behave as in most programming languages. The escape character is \r
173 backslash (\92\\92). In order to get a quotation mark you enter \\94. The full list of \r
174 valid sequences is just below.\r
175 \r
176         \\94 - Quotation mark.\r
177         \\ - Backslash.\r
178         \n - New line\r
179 \r
180 These sequences apply to all parameters, it doesn\92t matter if it\92s a file name or \r
181 a long string of xml-data.\r
182 \r
183 **********************************************************************************\r
184 2.3. Command Specification\r
185 **********************************************************************************\r
186 \r
187 ----------------------------------------------------------------------------------\r
188 2.3.1. Required Value\r
189 ----------------------------------------------------------------------------------\r
190 Syntax: \r
191 \r
192         [my_value_name:my_type,my_type2]        \r
193 \r
194 Description: \r
195 \r
196         Required value with one of the comma separated types \93my_typex\94.\r
197 \r
198 Examples:\r
199 \r
200         [transition:CUT,MIX,PUSH,WIPE] - A required value for "transition" which \r
201                                          can be either CUT, MIX, PUSH or WIPE.\r
202         >> CUT\r
203         << CUT\r
204 \r
205         [channel:int] - A required value for "channel" which must a signed\r
206                         integer.\r
207         >> 1\r
208         << 1\r
209 ----------------------------------------------------------------------------------\r
210 2.3.2. Optional Expression\r
211 ----------------------------------------------------------------------------------\r
212 Syntax: \r
213 \r
214         {my_expr|my_default_expr}       \r
215 \r
216 Description: \r
217 \r
218         Optional expression where \93my_def_expr\94 is used if no expression \r
219         is provided. If |"my_def_expr" is not provided then it is \r
220         assumed to evaluate to |"".\r
221 \r
222 Examples:\r
223 \r
224         {-[layer:int]|-0} - An optional expression which will be evaluated\r
225                             to "-0" if not provided.\r
226         >> -2\r
227         << -2\r
228                         \r
229         >> \r
230         << -0\r
231 \r
232         {[tween:string]} - An optional expression will be evaluated to an \r
233                            emptry string if not provided.\r
234 \r
235         >> easeinsine\r
236         << easeinsine\r
237 \r
238         >>\r
239         <<\r
240 \r
241 **********************************************************************************\r
242 2.4. Basic Commands\r
243 **********************************************************************************\r
244 \r
245 ----------------------------------------------------------------------------------\r
246 2.4.1. LOADBG\r
247 ----------------------------------------------------------------------------------\r
248 Syntax: \r
249 \r
250         LOADBG [channel:int]{-[layer:int]|-0} [clip:string] {[loop:LOOP]}\r
251          {[transition:CUT,MIX,PUSH,WIPE] [duration:uint] {[tween:string]|linear} \r
252          {[direction:LEFT,RIGHT]|RIGHT}|CUT 0} {([start:uint]{,[length:uint]})|(0)}\r
253 \r
254 Description: \r
255 \r
256         Loads a clip in the background and prepares it for playout. \r
257         \r
258         The string "clip" will be parsed by available registered producer factories. If\r
259         a successfully match is found then the producer will be loaded into the background.\r
260         \r
261         If a file with the same name (extension excluded) but with the additional \r
262         postfix "_a" is found this file will be used as key for the main "clip".\r
263 \r
264         Supplying the "loop" value will cause the clip to loop.\r
265 \r
266 Examples:       \r
267         \r
268         LOADBG 1 MY_FILE PUSH 20 EASEINSINE\r
269         LOADBG 1-1 MY_FILE SLIDE 10 LEFT\r
270         LOADBG 1-0 MY_FILE\r
271 \r
272 Note: \r
273 \r
274         See Appendix A: Tweener for supported values for tween.\r
275 \r
276 ----------------------------------------------------------------------------------\r
277 2.4.2. LOAD\r
278 ----------------------------------------------------------------------------------\r
279 Syntax: \r
280 \r
281         LOAD [channel:int]{-[layer:int]|-0} [clip:string] {[loop:LOOP]} \r
282          {([start_frame:uint]{,[end_frame:uint]})|(0)}\r
283 \r
284 Description: \r
285 \r
286         Loads a clip to the foreground and plays the first frame before pausing. If\r
287         any clip is playing on the target foreground then this clip will be replaced.\r
288         \r
289 Examples: \r
290         \r
291         LOAD 1 MY_FILE\r
292         LOAD 1-1 MY_FILE\r
293 \r
294 Note:\r
295 \r
296         See 1.2.1. LOADBG for additional details.\r
297         \r
298 ----------------------------------------------------------------------------------\r
299 2.4.3. PLAY\r
300 ----------------------------------------------------------------------------------\r
301 Syntax:\r
302 \r
303         PLAY [channel:int]{-[layer:int]|-0} {"additional parameters"}\r
304          \r
305 Description: \r
306 \r
307         Moves clip from background to foreground and starts playing it. If a\r
308         transition (see LOADBG) is prepared it will be executed.\r
309         \r
310         If "additional  parameters" (see LOADBG) is provided then the provided clip \r
311         will first be loaded to the background.\r
312         \r
313 Examples:       \r
314 \r
315         >> PLAY 1 MY_FILE PUSH 20 EASEINSINE\r
316         >> PLAY 1-1 MY_FILE SLIDE 10 LEFT\r
317         >> PLAY 1-0 MY_FILE\r
318 \r
319 Note: \r
320 \r
321         See 1.2.1. LOADBG for additional details.\r
322 \r
323 ----------------------------------------------------------------------------------\r
324 2.4.4. PAUSE\r
325 ----------------------------------------------------------------------------------\r
326 Syntax:\r
327 \r
328         PAUSE [channel:int]{-[layer:int]|-0}\r
329 \r
330 Description: \r
331 \r
332         Pauses foreground clip.\r
333         \r
334 Examples:       \r
335         \r
336         >> PAUSE 1\r
337         >> PAUSE 1-1\r
338 \r
339 ----------------------------------------------------------------------------------\r
340 2.4.5. STOP\r
341 ----------------------------------------------------------------------------------\r
342 Syntax: \r
343 \r
344         PAUSE [channel:int]{-[layer:int]|-0}\r
345 \r
346 Description: \r
347 \r
348         Removes foreground clip.\r
349         \r
350 Examples:       \r
351 \r
352         >> STOP 1\r
353         >> STOP 1-1\r
354 \r
355 ----------------------------------------------------------------------------------\r
356 2.4.6. CLEAR\r
357 ----------------------------------------------------------------------------------\r
358 Syntax: \r
359 \r
360         CLEAR [channel:int]{-[layer:int]}\r
361 \r
362 Description: \r
363 \r
364         Removes all clips (both foreground and background). If no layer is specified \r
365         then all layers in the specified channel are cleared.\r
366         \r
367 Examples:       \r
368 \r
369         >> CLEAR 1\r
370         >> CLEAR 1-1\r
371 \r
372 ----------------------------------------------------------------------------------\r
373 2.4.7. SWAP\r
374 ----------------------------------------------------------------------------------\r
375 Syntax: \r
376 \r
377         SWAP [channel1:int]{-[layer1:int]} [channel2:int]{-[layer2:int]}\r
378 \r
379 Description: \r
380 \r
381         Swaps layers between channels (both foreground and background will be swapped). \r
382         If layers are not specified then all layers in respective channel will be swapped.\r
383         \r
384 Examples:       \r
385 \r
386         >> SWAP 1 2\r
387         >> SWAP 1-1 2-3\r
388         \r
389 ----------------------------------------------------------------------------------\r
390 2.4.8. ADD\r
391 ----------------------------------------------------------------------------------\r
392 Syntax: \r
393 \r
394         ADD [channel:int]{-[layer:int]|-0} [parameters:string]\r
395 \r
396 Description: \r
397 \r
398         The string "clip" will be parsed by available registered consumer factories. If\r
399         a successfull match is found a consumer will be created and added to the channel.\r
400 \r
401 Examples:       \r
402 \r
403         >> ADD 1 DECKLINK 1 PAL\r
404         >> ADD 1-2 BLUEFISH 1 PAL\r
405         \r
406 ----------------------------------------------------------------------------------\r
407 2.4.8. REMOVE\r
408 ----------------------------------------------------------------------------------\r
409 Syntax: \r
410 \r
411         REMOVE [channel:int]{-[layer:int]|-0}\r
412 \r
413 Description: \r
414 \r
415         Removes an existing consumer from channel.\r
416         \r
417 Examples:       \r
418 \r
419         >> REMOVE 1\r
420         >> REMOVE 1-2\r
421         \r
422 ----------------------------------------------------------------------------------\r
423 2.4.9. PARAM\r
424 ----------------------------------------------------------------------------------\r
425 Syntax: \r
426 \r
427         PARAM [channel:int]{-[layer:int]|-0} [param:string]\r
428 \r
429 Description: \r
430 \r
431         Calls param method on the specified producer with the provided "param" string.\r
432         \r
433 Examples:       \r
434 \r
435         >> PARAM 1 LOOP\r
436         >> PARAM 1-2 "SEEK_FRAME 25"\r
437 \r
438 **********************************************************************************\r
439 2.5. Data Commands\r
440 **********************************************************************************\r
441 The DATA commands are convenient to use when you have large datasets that might not \r
442 be available at broadcast-time. DATA allows you to store a dataset on the \r
443 CasparCG Server and assign it to a much shorter name. This name can then be used to \r
444 recall the data when displaying a template graphic.\r
445 \r
446 ----------------------------------------------------------------------------------\r
447 2.5.1. DATA STORE\r
448 ----------------------------------------------------------------------------------\r
449 Syntax:\r
450         \r
451         DATA STORE [name:string] [data:string]\r
452 \r
453 Description:\r
454 \r
455         Stores the dataset data under the name name.\r
456 \r
457 Examples:\r
458 \r
459         >> DATA STORE my_data "Some useful data"\r
460         \r
461 ----------------------------------------------------------------------------------\r
462 2.5.2. DATA RETRIEVE\r
463 ----------------------------------------------------------------------------------\r
464 Syntax:\r
465         \r
466         DATA RETRIEVE [name:string] [data:string]\r
467 \r
468 Description:\r
469 \r
470         Returns the data saved under the name "name".\r
471                 \r
472 ----------------------------------------------------------------------------------\r
473 2.5.3. DATA LIST\r
474 ----------------------------------------------------------------------------------\r
475 Syntax:\r
476         \r
477         DATA LIST\r
478 \r
479 Description:\r
480 \r
481         Returns a list of all saved datasets.\r
482         \r
483 **********************************************************************************\r
484 2.6. Template Graphics Commands\r
485 **********************************************************************************\r
486 \r
487 ----------------------------------------------------------------------------------\r
488 2.6.1. Template Data\r
489 ----------------------------------------------------------------------------------\r
490 Data to templates is sent in xml formatted as follows:\r
491 \r
492 <templateData>\r
493         <componentData id="f0">\r
494                 <data id="text" value="Niklas P Andersson" /> </componentData>\r
495         <componentData id="f1">\r
496                 <data id="text" value="Developer" />\r
497         </componentData>\r
498         <componentData id="f2">\r
499                 <data id="text" value="Providing an example" />\r
500         </componentData>\r
501 </templateData> \r
502 \r
503 The node under each componentData is sent directly into the specified component. \r
504 This makes it possible to provide completely custom data to templates. The data-nodes \r
505 in this example is just the way the default CasparCG textfield wants its data. \r
506 More information about this will be provided with the tools and actionscript classes \r
507 required to build your own templates.\r
508 \r
509 'A complete call' to CG ADD (see below), correctly escaped and with the data above \r
510 would look like this:\r
511 \r
512 CG 1 ADD 0 "demo/test" 1 "<templateData><componentData id=\"f0\"><data id=\"text\" \r
513 value=\"Niklas P Andersson\"></data> </componentData><componentData id=\"f1\"><data \r
514 id=\"text\" value=\"developer\"></data></componentData><componentData id=\"f2\"><data \r
515 id=\"text\" value=\"Providing an example\"></data> </componentData></templateData>"\r
516 \r
517 ----------------------------------------------------------------------------------\r
518 2.6.2. CG ADD\r
519 ----------------------------------------------------------------------------------\r
520 Syntax: \r
521 \r
522         CG [channel:int]{-[layer:int]|-0} ADD [flash_layer:uint] [template:string]\r
523          [play-on-load:0,1] [data]\r
524 \r
525 Description: \r
526 \r
527         Prepares a template for displaying. It won\92t show until you call CG PLAY \r
528         (unless you supply the play-on-load flag, 1 for true). Data is either inline \r
529         xml or a reference to a saved dataset. \r
530         Please see 2.5.1 for a complete example with data.\r
531         \r
532 Examples:       \r
533 \r
534         >> CG 1 ADD 10 svtnews/info 1\r
535 \r
536 ----------------------------------------------------------------------------------\r
537 2.6.2. CG REMOVE\r
538 ----------------------------------------------------------------------------------\r
539 Syntax: \r
540 \r
541         CG [channel:int]{-[layer:int]|-0} REMOVE [flash_layer:uint]\r
542 \r
543 Description: \r
544 \r
545         Removes the visible template from a specific layer.\r
546         \r
547 ----------------------------------------------------------------------------------\r
548 2.6.3. CG CLEAR\r
549 ----------------------------------------------------------------------------------\r
550 Syntax: \r
551 \r
552         CG [channel:int]{-[layer:int]|-0} CLEAR [flash_layer:uint]\r
553 \r
554 Description: \r
555 \r
556         Clears all layers and any state that might be stored. What this actually does \r
557         behind the scene is to create a new instance of the \r
558         Adobe Flash player ActiveX controller in memory.\r
559 \r
560 ----------------------------------------------------------------------------------\r
561 2.6.4. CG PLAY\r
562 ----------------------------------------------------------------------------------\r
563 Syntax: \r
564 \r
565         CG [channel:int]{-[layer:int]|-0} PLAY [flash_layer:uint]\r
566 \r
567 Description: \r
568 \r
569         Plays / displays the template in the specified layer.\r
570 \r
571 ----------------------------------------------------------------------------------\r
572 2.6.5. CG STOP\r
573 ----------------------------------------------------------------------------------\r
574 Syntax: \r
575 \r
576         CG [channel:int]{-[layer:int]|-0} STOP [flash_layer:uint]\r
577 \r
578 Description: \r
579 \r
580         Stops and removes the template from the specified layer. This is different \r
581         than REMOVE in that the template gets a chance to animate out when it is stopped.\r
582 \r
583 ----------------------------------------------------------------------------------\r
584 2.6.6. CG NEXT\r
585 ----------------------------------------------------------------------------------\r
586 Syntax: \r
587 \r
588         CG [channel:int]{-[layer:int]|-0} NEXT [flash_layer:uint]\r
589 \r
590 Description: \r
591 \r
592         Triggers a \94continue\94 in the template on the specified layer. This is used to \r
593         control animations that has multiple discreet steps.\r
594 \r
595 ----------------------------------------------------------------------------------\r
596 2.6.7. CG GOTO\r
597 ----------------------------------------------------------------------------------\r
598 Syntax: \r
599 \r
600         CG [channel:int]{-[layer:int]|-0} GOTO [flash_layer:uint] [label:string]\r
601 \r
602 Description: \r
603 \r
604         Jumps to the specified label in the template on the specified layer.\r
605 \r
606 ----------------------------------------------------------------------------------\r
607 2.6.8. CG UPDATE\r
608 ----------------------------------------------------------------------------------\r
609 Syntax: \r
610 \r
611         CG [channel:int]{-[layer:int]|-0} GOTO [flash_layer:uint] [data:string]\r
612 \r
613 Description: \r
614 \r
615         Sends new data to the template on specified layer. Data is either inline xml \r
616         or a reference to a saved dataset.\r
617 \r
618 ----------------------------------------------------------------------------------\r
619 2.6.9. CG INVOKE\r
620 ----------------------------------------------------------------------------------\r
621 Syntax: \r
622 \r
623         CG [channel:int]{-[layer:int]|-0} GOTO [flash_layer:uint] [method:string]\r
624 \r
625 Description: \r
626 \r
627         Calls a custom method in the document class of the template on the specified \r
628         layer. The method must return void and take no parameters.\r
629 \r
630 **********************************************************************************\r
631 2.7. Mixer Commands\r
632 **********************************************************************************\r
633 \r
634 ----------------------------------------------------------------------------------\r
635 2.7.1. MIXER VIDEO IS_KEY\r
636 ----------------------------------------------------------------------------------\r
637 Syntax: \r
638 \r
639         MIXER [channel:int]{-[layer:int]|-0} VIDEO IS_KEY {is_key:0,1|0}\r
640 \r
641 Description: \r
642 \r
643         If "is_key" equals 1 then the specified layer will not be rendered, \r
644         instead it will be used as the key for the layer above.\r
645         \r
646 Examples:       \r
647 \r
648         >> MIXER VIDEO 1-0 IS_KEY 1\r
649         \r
650 Note:\r
651 \r
652         See Appendix A: Tweener for supported values for tween.\r
653 \r
654 ----------------------------------------------------------------------------------\r
655 2.7.2. MIXER VIDEO OPACITY\r
656 ----------------------------------------------------------------------------------\r
657 Syntax: \r
658 \r
659         MIXER [channel:int]{-[layer:int]|-0} VIDEO OPACITY {opacity:float} \r
660          {[duration:uint] {[tween:string]|linear}|0 linear}\r
661 \r
662 Description: \r
663 \r
664         Changes the opacity of the specified layer.\r
665         \r
666 Examples:       \r
667 \r
668         >> MIXER VIDEO 1-0 OPACITY 0.5 25 easeinsine\r
669         \r
670 Note:\r
671 \r
672         See Appendix A: Tweener for supported values for tween.\r
673         \r
674 ----------------------------------------------------------------------------------\r
675 2.7.3. MIXER VIDEO GAIN\r
676 ----------------------------------------------------------------------------------\r
677 Syntax: \r
678 \r
679         MIXER [channel:int]{-[layer:int]|-0} VIDEO GAIN {opacity:float} \r
680          {[duration:uint] {[tween:string]|linear}|0 linear}\r
681 \r
682 Description: \r
683 \r
684         Changes the gain of the specified layer.\r
685         \r
686 Examples:       \r
687 \r
688         >> MIXER VIDEO 1-0 GAIN 0.5 25 easeinsine\r
689         \r
690 Note:\r
691 \r
692         See Appendix A: Tweener for supported values for tween.\r
693         \r
694 ----------------------------------------------------------------------------------\r
695 2.7.4. MIXER VIDEO FILL_RECT\r
696 ----------------------------------------------------------------------------------\r
697 Syntax: \r
698 \r
699         MIXER [channel:int]{-[layer:int]|-0} VIDEO FILL_RECT [x:float] [y:float]\r
700          [x-scale:float] [y-slace:float] {[duration:uint] {[tween:string]|linear}|0 linear}\r
701 \r
702 Description: \r
703 \r
704         Scales the video stream on the specified layer.\r
705         \r
706 Examples:       \r
707 \r
708         >> MIXER VIDEO 1-0 FILL_RECT 0.25 0.25 0.5 0.5 25 easeinsine\r
709 \r
710 Note:\r
711 \r
712         This feature is not yet fully supported (2011-05-12) for interlaced video sources \r
713         since the frames are not deinterlaced before scaling.\r
714         \r
715         See Appendix A: Tweener for supported values for tween.\r
716 \r
717 ----------------------------------------------------------------------------------\r
718 2.7.5. MIXER VIDEO KEY_RECT\r
719 ----------------------------------------------------------------------------------\r
720 Syntax: \r
721 \r
722         MIXER [channel:int]{-[layer:int]|-0} VIDEO KEY_RECT [x:float] [y:float]\r
723          [x-scale:float] [y-slace:float] {[duration:uint] {[tween:string]|linear}|0 linear}\r
724 \r
725 Description: \r
726 \r
727         Masks the video stream on the specified layer.\r
728         \r
729 Examples:       \r
730 \r
731         >> MIXER VIDEO 1-0 KEY_RECT 0.25 0.25 0.5 0.5 25 easeinsine\r
732         \r
733 Note:\r
734 \r
735         See Appendix A: Tweener for supported values for tween.\r
736                 \r
737 ----------------------------------------------------------------------------------\r
738 2.7.6. MIXER VIDEO GRID\r
739 ----------------------------------------------------------------------------------\r
740 Syntax: \r
741 \r
742         MIXER [channel:int] GRID [resolution:uint] VIDEO {[duration:uint] \r
743          {[tween:string]|linear}|0 linear}\r
744 \r
745 Description: \r
746 \r
747         Creates a grid of video streams in ascending order of the layer index, e.g.\r
748         if resolution equals 2 then a 2x2 grid of layers will be created.\r
749         \r
750 Examples:       \r
751 \r
752         >> MIXER VIDEO 1 GRID 2\r
753 \r
754 Note:\r
755 \r
756         This feature is not yet fully supported (2011-05-12) for interlaced video sources \r
757         since the frames are not deinterlaced before scaling.\r
758         \r
759         See Appendix A: Tweener for supported values for tween.\r
760 ----------------------------------------------------------------------------------\r
761 2.7.7. MIXER VIDEO RESET\r
762 ----------------------------------------------------------------------------------\r
763 Syntax: \r
764 \r
765         MIXER [channel:int]{-[layer:int]|-0} VIDEO RESET {[duration:uint] \r
766          {[tween:string]|linear}|0 linear}\r
767 \r
768 Description: \r
769 \r
770         Reset all video transformations.\r
771         \r
772 Examples:       \r
773 \r
774         >> MIXER VIDEO 1 RESET\r
775         >> MIXER VIDEO 1-0 RESET\r
776         \r
777 Note:\r
778 \r
779         See Appendix A: Tweener for supported values for tween.\r
780         \r
781 ----------------------------------------------------------------------------------\r
782 2.7.8. MIXER AUDIO GAIN\r
783 ----------------------------------------------------------------------------------\r
784 Syntax: \r
785 \r
786         MIXER [channel:int]{-[layer:int]|-0} AUDIO GAIN {opacity:float} \r
787          {[duration:uint] {[tween:string]|linear}|0 linear}\r
788 \r
789 Description: \r
790 \r
791         Changes the gain(volume) of the specified layer.\r
792         \r
793 Examples:       \r
794 \r
795         >> MIXER AUDIO 1-0 GAIN 0.5 25 easeinsine\r
796         \r
797 Note:\r
798 \r
799         See Appendix A: Tweener for supported values for tween.\r
800                 \r
801 ----------------------------------------------------------------------------------\r
802 2.7.9. MIXER AUDIO RESET\r
803 ----------------------------------------------------------------------------------\r
804 Syntax: \r
805 \r
806         MIXER [channel:int]{-[layer:int]|-0} AUDIO RESET {[duration:uint] \r
807          {[tween:string]|linear}|0 linear}\r
808 \r
809 Description: \r
810 \r
811         Reset all audio transformations.\r
812         \r
813 Examples:       \r
814 \r
815         >> MIXER AUDIO 1 RESET\r
816         >> MIXER AUDIO 1-0 RESET\r
817         \r
818 Note:\r
819 \r
820         See Appendix A: Tweener for supported values for tween.\r
821 \r
822 ----------------------------------------------------------------------------------\r
823 2.7.10. MIXER RESET\r
824 ----------------------------------------------------------------------------------\r
825 Syntax: \r
826 \r
827         MIXER [channel:int]{-[layer:int]|-0} RESET {[duration:uint] \r
828          {[tween:string]|linear}|0 linear}\r
829 \r
830 Description: \r
831 \r
832         Reset all transformations.\r
833         \r
834 Examples:       \r
835 \r
836         >> MIXER AUDIO 1 RESET\r
837         >> MIXER AUDIO 1-0 RESET\r
838         \r
839 Note:\r
840 \r
841         See Appendix A: Tweener for supported values for tween.\r
842 \r
843 **********************************************************************************\r
844 2.8. Query Commands\r
845 **********************************************************************************\r
846 \r
847 ----------------------------------------------------------------------------------\r
848 2.8.1. CINF\r
849 ----------------------------------------------------------------------------------\r
850 Syntax: \r
851 \r
852         CINF [filename:string]\r
853 \r
854 Description: \r
855 \r
856         Returns information about a mediafile.\r
857 \r
858 ----------------------------------------------------------------------------------\r
859 2.8.2. CLS\r
860 ----------------------------------------------------------------------------------\r
861 Syntax: \r
862 \r
863         CLS\r
864 \r
865 Description: \r
866 \r
867         Lists all mediafiles.\r
868 \r
869 ----------------------------------------------------------------------------------\r
870 2.8.3. TLS\r
871 ----------------------------------------------------------------------------------\r
872 Syntax: \r
873 \r
874         TLS {folder:string|./}\r
875 \r
876 Description: \r
877 \r
878         Lists all templates. Lists only templates in the specified folder, if provided.\r
879 \r
880 ----------------------------------------------------------------------------------\r
881 2.8.4. VERSION\r
882 ----------------------------------------------------------------------------------\r
883 Syntax: \r
884 \r
885         VERSION {[component:SERVER,FLASH,TEMPLATEHOST]|SERVER}\r
886 \r
887 Description: \r
888 \r
889         Returns the version of specified component.\r
890 \r
891         \r
892 ----------------------------------------------------------------------------------\r
893 2.8.5. INFO\r
894 ----------------------------------------------------------------------------------\r
895 Syntax: \r
896 \r
897         INFO [channel:int]\r
898 \r
899 Description: \r
900 \r
901         Returns information about the channels on the server. Use this without parameters \r
902         to check how many channels a server has.\r
903         \r
904 **********************************************************************************\r
905 2.9. Misc Commands\r
906 **********************************************************************************\r
907 \r
908 ----------------------------------------------------------------------------------\r
909 2.9.1. BYE\r
910 ----------------------------------------------------------------------------------\r
911 Syntax: \r
912 \r
913         BYE\r
914 \r
915 Description: \r
916 \r
917         Disconnects from the server.\r
918         \r
919 **********************************************************************************\r
920 2.10. Return Codes\r
921 **********************************************************************************\r
922                 \r
923 ----------------------------------------------------------------------------------\r
924 2.10.1. Information\r
925 ----------------------------------------------------------------------------------\r
926 \r
927         100 [action] - Information about an event.\r
928         101 [action] - Information about an event. A line of data is being returned.\r
929         \r
930 ----------------------------------------------------------------------------------\r
931 2.10.2. Successfull\r
932 ----------------------------------------------------------------------------------\r
933 \r
934         200 [command] OK                - The command has been executed\r
935         201 [command] OK                - The command has been executed and a line of data is\r
936                                                         being returned\r
937         202 [command] OK                - The command has been executed and several lines of\r
938                                                         data are being returned (terminated by an empty line).\r
939 \r
940 ----------------------------------------------------------------------------------\r
941 2.10.3. Client Error\r
942 ----------------------------------------------------------------------------------\r
943 \r
944         400 ERROR                               - Command not understood\r
945         401 [command] ERROR             - Illegal channel\r
946         402 [command] ERROR             - Parameter missing\r
947         403 [command] ERROR             - Illegal parameter\r
948         404 [command] ERROR             - Media file not found\r
949 \r
950 ----------------------------------------------------------------------------------\r
951 2.10.4. Server Error\r
952 ----------------------------------------------------------------------------------\r
953 \r
954         500 FAILED                              - Internal server error\r
955         501 [command] FAILED    - Internal server error\r
956         502 [command] FAILED    - Media file unreadable\r
957 \r
958 ==================================================================================\r
959 APPENDIX A : TWEENER\r
960 ==================================================================================\r
961 \r
962 The following list specifies all supported tweens.\r
963 \r
964 linear                  \r
965 easenone                \r
966 easeinquad              \r
967 easeoutquad     \r
968 aseinoutquad    \r
969 easeoutinquad   \r
970 easeincubic     \r
971 easeoutcubic    \r
972 easeinoutcubic\r
973 easeoutincubic\r
974 easeinquart     \r
975 easeoutquart    \r
976 easeinoutquart\r
977 easeoutinquart\r
978 easeinquint     \r
979 easeoutquint    \r
980 easeinoutquint\r
981 easeoutinquint\r
982 easeinsine              \r
983 easeoutsine     \r
984 easeinoutsine   \r
985 easeoutinsine   \r
986 easeinexpo              \r
987 easeoutexpo     \r
988 easeinoutexpo   \r
989 easeoutinexpo   \r
990 easeincirc              \r
991 easeoutcirc     \r
992 easeinoutcirc   \r
993 easeoutincirc   \r
994 easeinelastic   \r
995 easeoutelastic\r
996 easeinoutelastic\r
997 easeoutinelastic\r
998 easeinback              \r
999 easeoutback     \r
1000 easeinoutback   \r
1001 easeoutintback\r
1002 easeoutbounce   \r
1003 easeinbounce    \r
1004 easeinoutbounce\r
1005 easeoutinbounce\r
1006 \r
1007 \r
1008 \r