Manual addition.
[dcpomatic.git] / doc / manual / dcpomatic.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <!DOCTYPE book [
3 <!ENTITY % sgml.features "IGNORE">
4 <!ENTITY % xml.features "INCLUDE">
5 <!ENTITY % dbcent PUBLIC "-//OASIS//ENTITIES DocBook Character Entities V4.5//EN"
6    "/usr/share/xml/docbook/schema/dtd/4.5/dbcentx.mod">
7 %dbcent;
8 <!ENTITY % extensions SYSTEM "extensions.ent">
9 %extensions;
10 ]>
11 <book xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
12
13 <!-- By good luck or good management, the scale parameter to imagedata
14      appears only to affect PDF output.  HTML scaling is done in the
15      Makefile.
16 -->
17
18 <bookinfo>
19 <title>DCP-o-matic</title>
20 <author><firstname>Carl</firstname><surname>Hetherington</surname></author>
21 </bookinfo>
22
23 <chapter xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
24 <title>Introduction</title>
25
26 <para>
27 Hello, and welcome to DCP-o-matic!
28 </para>
29
30 <section>
31 <title>What is DCP-o-matic?</title>
32
33 <para>
34 DCP-o-matic is a program to generate <ulink
35 url="http://en.wikipedia.org/wiki/Digital_Cinema_Package">Digital
36 Cinema Packages</ulink> (DCPs) from DVDs, Blu-Rays, video files such as MP4
37 and AVI, or still images.  The resulting DCPs will play on modern digital
38 cinema projectors.
39 </para>
40
41 <para>
42 You might find it useful to make DVDs easier to present, to encode
43 independently-shot feature films, or to generate local advertising for
44 your cinema.
45 </para>
46
47 </section>
48
49 <section>
50 <title>Licence</title>
51
52 <para>
53 DCP-o-matic is licensed under the <ulink url="http://www.gnu.org/licenses/old-licenses/gpl-2.0.html">GNU GPL</ulink>.
54 </para>
55
56 </section>
57
58 <section>
59 <title>Acknowledgements</title>
60
61 <para>
62 This manual uses icons from the <ulink url="http://tango.freedesktop.org/">Tango Desktop Project</ulink>, with thanks.
63 </para>
64
65 </section>
66 </chapter>
67
68 <chapter xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
69 <title>Installation</title>
70
71 <section>
72 <title>Windows</title>
73
74 <para>
75 To install DCP-o-matic on Windows, simply download the installer from
76 <ulink url="http://dcpomatic.com/">http://dcpomatic.com/</ulink>
77 and double-click it.  Click through the installer wizard, and
78 DCP-o-matic will be installed onto your machine.
79 </para>
80
81 <para>
82 If you are using a 32-bit version of Windows, you will need the 32-bit
83 installer.  For 64-bit Windows, either installer will work, but I
84 suggest you used the 64-bit version as it will allow DCP-o-matic to
85 use more memory.  You may find that DCP-o-matic crashes if you run
86 many parallel encoding threads (more than 4) on the 32-bit
87 version.
88 </para>
89
90 </section>
91
92 <section>
93 <title>Mac OS X</title>
94
95 <para>
96 DCP-o-matic will run on Mac OS X version 10.6 (Snow Leopard) and
97 higher.  To install it, download the <code>DMG</code> from <ulink
98 url="http://dcpomatic.com/">http://dcpomatic.com/</ulink> and double
99 click to open it.  Then drag the DCP-o-matic icon to your
100 <guilabel>Applications</guilabel> folder or wherever else you would
101 like to install it.
102 </para>
103
104 </section>
105
106 <section>
107 <title>Ubuntu Linux</title>
108
109 <para>
110 You can install DCP-o-matic on Ubuntu 12.04 (&lsquo;Precise
111 Pangolin&rsquo;), 12.10 (&lsquo;Quantal Quetzal&rsquo;) or 13.04
112 (&lsquo;Raring Ringtail&rsquo;) using <code>.deb</code> packages:
113 download the appropriate package from <ulink
114 url="http://dcpomatic.com/">http://dcpomatic.com/</ulink> and
115 double-click it.  Ubuntu will install the necessary bits and pieces
116 and set DCP-o-matic up for you.
117 </para>
118
119 </section>
120
121 <section>
122 <title>Other Linux distributions</title>
123
124 <para>
125 Installation on non-Ubuntu Linux is currently a little involved, as
126 there are no packages available (yet); you will have to compile it
127 from source.  If you are using a non-Ubuntu distribution, do let me
128 know via the <ulink url="mailto:carl@dcpomatic.com">mailing
129 list</ulink> and I will see about building some packages.
130 </para>
131
132 <para>
133 The following dependencies are required:
134 <itemizedlist>
135 <listitem><ulink url="http://ffmpeg.org/">FFmpeg</ulink></listitem>
136 <listitem><ulink url="http://www.mega-nerd.com/libsndfile/">libsndfile</ulink></listitem>
137 <listitem><ulink url="http://www.openssl.org/">OpenSSL</ulink></listitem>
138 <listitem><ulink url="http://www.openjpeg.org/">libopenjpeg</ulink></listitem>
139 <listitem><ulink url="http://www.imagemagick.org/script/index.php">ImageMagick</ulink></listitem>
140 <listitem><ulink url="http://www.boost.org/">Boost</ulink></listitem>
141 <listitem><ulink url="http://www.libssh.org/">libssh</ulink></listitem>
142 <listitem><ulink url="http://www.gtk.org/">GTK</ulink></listitem>
143 <listitem><ulink url="http://www.wxwidgets.org/">wxWidgets</ulink></listitem>
144 <listitem><ulink url="http://carlh.net/software/libdcp/">libdcp</ulink></listitem>
145 <listitem><ulink url="http://carlh.net/software/libcxml/">libcxml</ulink></listitem>
146 </itemizedlist>
147 </para>
148
149 <para>
150 Once you have installed the development packages for the dependencies,
151 download the source code from <ulink
152 url="http://dcpomatic.com/">http://dcpomatic.com/</ulink>,
153 unpack it and run the following commands from inside the source
154 directory:
155 </para>
156
157 <programlisting>
158 ./waf configure
159 ./waf build
160 sudo ./waf install
161 </programlisting>
162
163 <para>
164 With any luck, this will build and install DCP-o-matic on your system.  To run it, enter:
165 </para>
166
167 <programlisting>
168 dcpomatic
169 </programlisting>
170
171 <para>
172 in a shell.
173 </para>
174
175 </section>
176 </chapter>
177
178 <chapter xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
179 <title>Creating a video DCP</title>
180
181 <para>
182 In this chapter we will see how to create a video DCP using
183 DCP-o-matic.  We will gloss over the details and look at the basics.
184 </para>
185
186 <section>
187 <title>Creating a new film</title>
188
189 <para>
190 Let's make a very simple DCP to see how DCP-o-matic works.  First, we
191 need some content.  Download the low-resolution trailer for the open
192 movie <ulink url="http://sintel.org/">Sintel</ulink> from <ulink
193 url="http://ftp.nluug.nl/ftp/graphics/blender/apricot/trailer/Sintel_Trailer1.480p.DivX_Plus_HD.mkv">their
194 website</ulink>.  Generally, of course, one would want to use the
195 highest-resolution material available, but for this test we will use
196 the low-resolution version to save everyone's bandwidth bills.
197 </para>
198
199 <para>
200 Now, start DCP-o-matic and its window will open.  First, we will
201 create a new &lsquo;film&rsquo;.  A &lsquo;film&rsquo; is how DCP-o-matic refers to
202 some pieces of content, along with some settings, which we will make into
203 a DCP.  DCP-o-matic stores its data in a folder on your disk while it
204 creates the DCP.  You can create a new film by selecting
205 <guilabel>New</guilabel> from the <guilabel>File</guilabel> menu, as
206 shown in <xref linkend="fig-file-new"/>.
207 </para>
208
209 <figure id="fig-file-new">
210   <title>Creating a new film</title> 
211   <mediaobject>
212     <imageobject> 
213       <imagedata fileref="screenshots/file-new&scs;"/>
214     </imageobject> 
215   </mediaobject>
216 </figure>
217
218 <para>
219 This will open a dialogue box for the new film, as shown in <xref
220 linkend="fig-video-new-film"/>.
221 </para>
222
223 <figure id="fig-video-new-film">
224   <title>Dialogue box for creating a new film</title> 
225   <mediaobject>
226     <imageobject> 
227       <imagedata fileref="screenshots/video-new-film&scs;"/>
228     </imageobject> 
229   </mediaobject>
230 </figure>
231
232 <para>
233 In this dialogue box you can choose a name for the film.  This will be
234 used to name the folder to store its data in, and also as the initial
235 name for the DCP itself.  You can also choose whereabouts you want to create
236 the film.  In the example from the figure, DCP-o-matic will create a
237 folder called &lsquo;DCP Test&rsquo; inside my home folder (carl) into which it
238 will write its working files.
239 </para>
240
241 </section>
242
243 <section>
244 <title>Adding content</title>
245
246 <para>
247 The next step is to add the content that you want to use.  DCP-o-matic
248 can make DCPs from multiple pieces of content, but in this simple
249 example we will just use a single piece.  Click the <guilabel>Add
250 file(s)...</guilabel> button, as shown in <xref
251 linkend="fig-add-file"/>, and a file chooser will open for you to
252 select the content file to use, as shown in <xref
253 linkend="fig-video-select-content-file"/>.
254 </para>
255
256 <figure id="fig-add-file"> 
257   <title>Adding content files</title> 
258   <mediaobject>
259     <imageobject> 
260       <imagedata fileref="screenshots/add-file&scs;"/>
261     </imageobject> 
262   </mediaobject>
263 </figure>
264
265 <figure id="fig-video-select-content-file"> 
266   <title>Selecting a video content file</title> 
267   <mediaobject>
268     <imageobject> 
269       <imagedata fileref="screenshots/video-select-content-file&scs;"/>
270     </imageobject> 
271   </mediaobject>
272 </figure>
273
274 <para>
275 Select your content file and click <guilabel>Open</guilabel>.  In this
276 case we are using the Sintel trailer that we downloaded earlier.
277 </para>
278
279 <para>
280 When you do this, DCP-o-matic will take a look at your file.  After a
281 short while (when the progress bar at the bottom right of the window
282 has finished), you can look through your content using the slider to
283 the right of the window, as shown in <xref linkend="fig-examine-content"/>.
284 </para>
285
286 <figure id="fig-examine-content"> 
287   <title>Examining the content</title>
288   <mediaobject>
289     <imageobject> 
290       <imagedata fileref="screenshots/examine-content&scs;"/>
291     </imageobject> 
292   </mediaobject>
293 </figure>
294
295 <para>
296 Dragging the slider will move through your video.  You can also click
297 the <guilabel>Play</guilabel> button to play the content back.  Note
298 that there will be no sound, and playback might not be entirely
299 accurate (it may be slightly slower or faster than it should be, for
300 example).  This player is really only intended for brief inspection of
301 content; if you need to check it more thoroughly, use another player
302 such as <ulink
303 url="http://projects.gnome.org/totem/index.html">Totem</ulink>, <ulink
304 url="http://www.mplayerhq.hu/design7/news.html">mplayer</ulink> or
305 <ulink url="http://www.videolan.org/vlc/index.html">VLC</ulink>.
306 </para>
307
308 </section>
309
310
311
312 <section>
313 <title>Making the DCP</title>
314
315 <para>In most cases, some adjustments would be made to DCP-o-matic's
316 settings once the content has been added.  For our simple test,
317 however, the default values will suffice, so we can go straight onto
318 making the DCP.</para>
319
320 <para>
321 Choose <guilabel>Make DCP</guilabel> from the
322 <guilabel>Jobs</guilabel> menu.  DCP-o-matic will encode your DCP.
323 This may take some time (many hours in some cases).  While the job is
324 in progress, DCP-o-matic will update you on how it is getting on with
325 the progress bar in the bottom of its window, as shown in <xref
326 linkend="fig-making-dcp"/>.
327 </para>
328
329 <figure id="fig-making-dcp">
330   <title>Making the DCP</title>
331   <mediaobject>
332     <imageobject> 
333       <imagedata scale="30" fileref="screenshots/making-dcp&scs;"/>
334     </imageobject> 
335   </mediaobject>
336 </figure>
337
338 <para>
339 When it has finished, the DCP will end up on your disk inside the
340 film's folder.  You can then copy this to a projector via a USB
341 stick, hard-drive or network connection.  See <xref
342 linkend="ch-files"/> for details about the files that DCP-o-matic creates.
343 </para>
344
345 <para>
346 Alternatively, if you have a projector or TMS that is accessible via
347 SCP across your network, you can upload the content directly from
348 DCP-o-matic.  See the preferences in <xref linkend="sec-prefs-tms"/>.
349 </para>
350
351 </section>
352 </chapter>
353
354 <chapter xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
355 <title>Creating a still-image DCP</title>
356
357 <para>
358 DCP-o-matic can also be used to create DCPs of one or more still images, perhaps
359 for an advertisement or an on-screen announcement.  This chapter shows you
360 how to do it.
361 </para>
362
363 <para>
364 As with video DCPs, the first step is to create a new
365 &lsquo;Film&rsquo;; select <guilabel>New</guilabel> from the
366 <guilabel>File</guilabel> menu and the new film dialogue will open as
367 shown in <xref linkend="fig-still-new-film"/>.
368 </para>
369
370 <figure id="fig-still-new-film"> 
371   <title>Dialogue box for creating a new film</title> 
372   <mediaobject>
373     <imageobject> 
374       <imagedata fileref="screenshots/still-new-film&scs;"/>
375     </imageobject> 
376   </mediaobject>
377 </figure>
378
379 <para>
380 Enter a name and click <guilabel>OK</guilabel>.  Now we need to add
381 the content.  As before, click <guilabel>Add file(s)...</guilabel>.
382 For our example, we will add a single image file, as shown in <xref
383 linkend="fig-still-select-content-file"/>.
384 </para>
385
386 <figure id="fig-still-select-content-file"> 
387   <title>Selecting a still content file</title> 
388   <mediaobject>
389     <imageobject> 
390       <imagedata fileref="screenshots/still-select-content-file&scs;"/>
391     </imageobject> 
392   </mediaobject>
393 </figure>
394
395 <para>
396 As with video DCPs, most of the default settings will be fine for a
397 simple test.  The one thing that you might wish to change is the
398 length of the still.  Select the <guilabel>Timing</guilabel> tab and
399 you will see a <guilabel>Length</guilabel> setting, as shown in <xref
400 linkend="fig-timing-tab"/>.
401 </para>
402
403 <figure id="fig-timing-tab"> 
404   <title>The timing tab</title>
405   <mediaobject>
406     <imageobject> 
407       <imagedata fileref="screenshots/timing-tab&scs;"/>
408     </imageobject> 
409   </mediaobject>
410 </figure>
411
412 <para>
413 This length is a &lsquo;timecode&rsquo;: it consists of four numbers.
414 The first is hours, the second minutes, the third seconds, and the
415 fourth frames.  Enter the duration that you want and then click <guilabel>Set</guilabel>.
416 </para>
417
418 <para>
419 Finally, as with video, you can choose <guilabel>Make DCP</guilabel>
420 from the <guilabel>Jobs</guilabel> menu to create your DCP.  This will
421 be much quicker than creating a video DCP, as DCP-o-matic only needs
422 to encode a single frame which it can then repeat.
423 </para>
424
425 </chapter>
426
427 <chapter xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
428 <title>Content settings</title>
429
430 <para>
431 The previous chapters showed DCP generation using the default
432 settings.  DCP-o-matic offers a range of features to adjust the
433 content that goes into your DCP, and this chapter describes those features in
434 detail.
435 </para>
436
437 <section>
438 <title>Adding and removing content</title>
439
440 <para>
441 At the top of the <guilabel>Content</guilabel> tab is a list of the
442 content that will go into our DCP.  There can be as many pieces of
443 content as you like, and they can be of the following types:
444 </para>
445
446 <itemizedlist>
447 <listitem>Movie &mdash; a file containing some video, probably some
448 audio and possibly some subtitles; for example, a MOV, MP4 or VOB.
449 </listitem>
450
451 <listitem>Sound &mdash; a file containing one or more channels of
452 audio; for example, a WAV or AIFF file.
453 </listitem>
454
455 <listitem>Still image &mdash; a file containing a single still image; for
456 example, a JPEG, PNG or TIFF file.
457 </listitem>
458
459 <listitem>Moving image &mdash; a directory containing many still
460 images which should be treated as the frames of a video.
461 </listitem>
462 </itemizedlist>
463
464 <para>
465 To add one or more movie, sound or still-image files, select
466 <guilabel>Add file(s)...</guilabel> and choose them from the selector.
467 To add a directory of images, choose <guilabel>Add
468 directory...</guilabel> and do similar.
469 </para>
470
471 <para>
472 You can remove a piece of content by clicking on its name and then
473 clicking the <guilabel>Remove</guilabel> button.
474 </para>
475
476 </section>
477 <section>
478 <title>Content Properties</title>
479
480 <para>
481 Below the content list are the controls to set content properties.  To
482 adjust the properties for a piece of content, click its name in the
483 content list.  The content property controls will then become active
484 for that piece of content.
485 </para>
486
487 <para>
488 The content properties are split up into four sections:
489 <guilabel>Video</guilabel>, <guilabel>Audio</guilabel>,
490 <guilabel>Subtitles</guilabel> and <guilabel>Timing</guilabel>.  Not
491 all of these sections will be active for all content types.  The controls
492 in each section are described below.
493 </para>
494
495 </section>
496
497 <section>
498 <title>Video</title>
499
500 <para>
501 The <guilabel>Video</guilabel> tab controls properties of the image, as shown in <xref linkend="fig-video-tab"/>.
502 </para>
503
504 <figure id="fig-video-tab"> 
505   <title>Video settings tab</title>
506   <mediaobject>
507     <imageobject> 
508        <imagedata fileref="screenshots/video-tab&scs;"/>
509     </imageobject> 
510   </mediaobject>
511 </figure>
512
513 <section>
514 <title>Image type</title>
515
516 <para>
517 The first option on this tab is the &lsquo;type&rsquo; of the video.
518 This specifies how DCP-o-matic should interpret the video's image.
519 <guilabel>2D</guilabel> is the default; this just takes the video
520 image as a standard 2D frame.  The other option <guilabel>3D
521 left/right</guilabel> tells DCP-o-matic to interpret the frame as a
522 left-right pair, as shown in <xref linkend="fig-3d-left-right"/>.
523 </para>
524
525 <figure id="fig-3d-left-right"> 
526   <title>3D left/right image type</title>
527   <mediaobject>
528     <imageobject> 
529        <imagedata scale="100" fileref="diagrams/3d-left-right&dia;"/>
530     </imageobject> 
531   </mediaobject>
532 </figure>
533
534 <para>
535 This option can be used to generate a 3D DCP.  Other means of creating
536 3D will be added in the future.
537 </para>
538
539 </section>
540
541
542 <!-- ============================================================== -->
543 <section>
544 <title>Filtering</title>
545
546 <para>
547 The &lsquo;filters&rsquo; settings allow you to apply various video
548 filters to the image.  These may be useful to try to improve
549 poor-quality sources like DVDs.  You can set up the filters by clicking the
550 <guilabel>Edit</guilabel> button next to the filters entry in the
551 setup area of the DCP-o-matic window; this opens the filters selector
552 as shown in <xref linkend="fig-filters"/>.
553 </para>
554
555 <figure id="fig-filters"> 
556   <title>Filters selector</title> 
557   <mediaobject>
558     <imageobject> 
559       <imagedata fileref="screenshots/filters&scs;"/>
560     </imageobject> 
561   </mediaobject>
562 </figure>
563
564 <para>
565 After changing the filters setup, you will need to regenerate the DCP
566 to see the effect on the cinema screen.  The preview in DCP-o-matic
567 will update itself whenever filters are changed, though of course this
568 image is much smaller and of lower resolution than a projected image!
569 </para>
570 </section>
571
572
573 <!-- ============================================================== -->
574 <section>
575 <title>Other settings</title>
576
577 <para>
578 The &lsquo;crop&rsquo; settings can be used to crop your content,
579 which can be used to remove black borders from round the edges of DVD
580 images, for example.  The specified number of pixels will be trimmed
581 from each edge, and the content image in the right of the window will
582 be updated to show the effect of the crop.
583 </para>
584
585 <para>
586 The <guilabel>Scale to</guilabel> option governs the shape that
587 DCP-o-matic will scale the content's image into.  Select the aspect
588 ratio that your content should be presented in.
589 </para>
590
591 </section>
592 <section>
593 <title>Video description</title>
594
595 <para>
596 At the bottom of the video tab is a short description of what will
597 happen to your video with the current settings.  In the example of
598 <xref linkend="fig-video-tab"/>, DCP-o-matic is telling you that the
599 video file is 1920x1080 pixels (which is a ratio of 1.78:1).  Since
600 the controls specify &lsquo;Flat&rsquo; for the ratio, DCP-o-matic
601 scales the content image to 1998x1080, which is the DCI flat
602 resolution at 2K.
603 </para>
604
605 <para>
606 This description also gives the frame rate of the content and what
607 will happen to it when it is played at the DCP's frame rate.
608 <!-- XXX: link to more detailed discussion of this -->
609 </para>
610
611 </section>
612
613 </section>
614
615 <section>
616 <title>Audio</title>
617
618 <para>
619 The <guilabel>Audio</guilabel> tab controls properties of the image, as shown in <xref linkend="fig-audio-tab"/>.
620 </para>
621
622 <figure id="fig-audio-tab"> 
623   <title>Audio settings tab</title>
624   <mediaobject>
625     <imageobject> 
626        <imagedata fileref="screenshots/audio-tab&scs;"/>
627     </imageobject> 
628   </mediaobject>
629 </figure>
630
631 <section>
632 <title>Show audio</title>
633
634 <para>
635 The <guilabel>Show Audio</guilabel> button will instruct DCP-o-matic
636 to examine the audio in your content and plot a graph of its level
637 over time.  This can be useful for getting a rough idea of how loud
638 the sound will be in the cinema auditorium.  A typical plot is shown
639 in <xref linkend="fig-audio-plot"/>
640 </para>
641
642 <figure id="fig-audio-plot"> 
643   <title>Audio plot</title>
644   <mediaobject>
645     <imageobject> 
646        <imagedata fileref="screenshots/audio-plot&scs;"/>
647     </imageobject> 
648   </mediaobject>
649 </figure>
650
651 <para>
652 The plot gives the audio level (vertical axis, in dB) with time
653 (horizontal axis).  0dB represents full scale, so if there is anything
654 near this you are in danger of clipping the projector's audio outputs.
655 </para>
656
657 <para>
658 There are two plot types: the peak level and the RMS, which can be
659 shown or hidden using the check-boxes on the right hand side of the
660 window.
661 </para>
662
663 <para>
664 The channel check-boxes will show or hide the plot(s) for
665 the corresponding channels in the DCP.
666 </para>
667
668 <para>
669 The smoothing slider applies a variable degree of temporal smoothing
670 to the plots, which can make them easier to read in some cases.
671 </para>
672
673 <para>
674 Obviously the audio plot is no substitute for listening in an
675 auditorium, but it can be useful to get levels in the right rough area.
676 </para>
677
678 </section>
679
680 <section>
681 <title>The audio map</title>
682
683 <para>
684 The section at the bottom of the audio tab is the &lsquo;audio
685 map&rsquo;.  This governs how sound from the content will be arranged
686 in the DCP.
687 </para>
688
689 <para>
690 Down the left-hand side of the map is the list of audio channels in
691 the currently-selected piece of content.  Along the top is each
692 channel in the DCP.  A checked box means that the corresponding
693 content channel will be copied into the corresponding DCP channel.
694 </para>
695
696 <para>
697 Consider, for example, the case in <xref linkend="fig-audio-map-eg1"/>.
698 </para>
699
700 <figure id="fig-audio-map-eg1">
701   <title>Audio map example 1</title>
702   <mediaobject>
703     <imageobject> 
704        <imagedata fileref="screenshots/audio-map-eg1&scs;"/>
705     </imageobject> 
706   </mediaobject>
707 </figure>
708
709 <para>
710 Here, we have two channels in the source which are mapped to left and
711 right, respectively, in the DCP.  If we modify that as in <xref
712 linkend="fig-audio-map-eg2"/>
713 </para>
714
715 <figure id="fig-audio-map-eg2">
716   <title>Audio map example 2</title>
717   <mediaobject>
718     <imageobject> 
719        <imagedata fileref="screenshots/audio-map-eg2&scs;"/>
720     </imageobject> 
721   </mediaobject>
722 </figure>
723
724 <para>
725 we now have the content's streams mapped to left and right and also
726 mixed together and placed in the DCP's centre channel.
727 </para>
728
729 <figure id="fig-audio-map-eg3">
730   <title>Audio map example 3</title>
731   <mediaobject>
732     <imageobject> 
733        <imagedata fileref="screenshots/audio-map-eg3&scs;"/>
734     </imageobject> 
735   </mediaobject>
736 </figure>
737
738 <para>
739 As a final example, the map in <xref linkend="fig-audio-map-eg3"/>
740 shows the mapping of a 5.1 source into a 5.1 DCP.
741 </para>
742
743 </section>
744
745 <section>
746 <title>Other controls</title>
747
748 <para>
749 &lsquo;Audio Gain&rsquo; is used to alter the volume of the
750 soundtrack.  The specified gain (in dB) will be applied to each sound
751 channel of your content before it is written to the DCP.
752 </para>
753
754 <para>
755 If you use a sound processor that DCP-o-matic knows about, it can help
756 you calculate changes in gain that you should apply.  Say, for
757 example, that you make a test DCP and find that you have to run it at
758 volume 5 instead of volume 7 to get a good sound level in the screen.
759 If this is the case, click the <guilabel>Calculate...</guilabel>
760 button next to the audio gain entry, and the dialogue box in <xref
761 linkend="fig-calculate-audio-gain"/> will open.
762 </para>
763
764 <figure id="fig-calculate-audio-gain"> 
765   <title>Calculating audio gain</title>
766   <mediaobject>
767     <imageobject> 
768       <imagedata fileref="screenshots/calculate-audio-gain&scs;"/>
769     </imageobject> 
770   </mediaobject>
771 </figure>
772
773 <para>
774 For our example, put 5 in the first box and 7 in the second and click
775 <guilabel>OK</guilabel>.  DCP-o-matic will calculate the audio gain
776 that it should apply to make this happen.  Then you can re-make the
777 DCP (this will be reasonably fast, as the video data will already have
778 been done) and it should play back at the correct volume with 7 on
779 your sound-rack fader.
780 </para>
781
782 <para>
783 Current versions of DCP-o-matic only know about the Dolby CP750.  If
784 you use a different sound processor, and know the gain curve of its
785 volume control, <ulink url="mailto:cth@carlh.net">get in
786 touch</ulink>.
787 </para>
788
789 <para>
790 <guilabel>Audio Delay</guilabel> is used to adjust the synchronisation
791 between audio and video.  A positive delay will move the audio later
792 with respect to the video, and a negative delay will move it earlier.
793 </para>
794
795 <para>
796 The <guilabel>Audio Stream</guilabel> option allows you to select the
797 audio stream to use, if the content contains more than one.  There
798 might be different soundtrack languages, for example.
799 </para>
800
801 </section>
802 </section>
803
804
805 <section>
806 <title>Subtitles</title>
807
808 <para>
809 The subtitles tab contains settings related to subtitles in your
810 content, as shown in <xref linkend="fig-subtitles-tab"/>.
811 </para>
812
813 <figure id="fig-subtitles-tab"> 
814   <title>Subtitle settings tab</title>
815   <mediaobject>
816     <imageobject> 
817        <imagedata fileref="screenshots/subtitles-tab&scs;"/>
818     </imageobject> 
819   </mediaobject>
820 </figure>
821
822 <para>
823 DCP-o-matic will extract subtitles from the content, if present, and
824 they can be &lsquo;burnt into&rsquo; the DCP (that is, they are
825 included in the image and not overlaid by the projector).  Note that
826 DVD and Blu-Ray subtitles are stored as bitmaps, so it is not possible
827 (automatically) to use non-burnt-in subtitles with these sources.
828 Select the <guilabel>With Subtitles</guilabel> check-box to enable
829 subtitles.  The <guilabel>offset</guilabel> control moves the
830 subtitles up and down the image, and the <guilabel>scale</guilabel>
831 control changes their size.
832 </para>
833
834 <para>
835 All being well, future versions of DCP-o-matic will include the option to
836 use text subtitles (as is the norm with most professionally-mastered
837 DCPs).
838 </para>
839
840 </section>
841
842 <!-- XXX: timing tab -->
843
844 </chapter>
845
846 <chapter xml:id="ch-dcp" xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
847 <title>DCP settings</title>
848
849 <para>
850 This chapter describes the settings that apply to the whole DCP.  The
851 controls for these settings are in the <guilabel>DCP</guilabel> tab of
852 the main window, as shown in <xref linkend="fig-dcp-tab"/>.
853 </para>
854
855 <figure id="fig-dcp-tab"> 
856   <title>DCP settings tab</title>
857   <mediaobject>
858     <imageobject> 
859        <imagedata fileref="screenshots/dcp-tab&scs;"/>
860     </imageobject> 
861   </mediaobject>
862 </figure>
863
864 <para>
865 The first thing here is the name.  This is generally set to the title
866 of the film that is being encoded.  If <guilabel>Use DCI
867 name</guilabel> is not ticked, the name that you specify will be used
868 as-is for the name of the DCP.  If <guilabel>Use DCI name</guilabel>
869 is ticked, the name that you enter will be used as part of a
870 DCI-compliant name.  
871 </para>
872
873 <para>
874 Underneath the name field is a preview of the name that the DCP will
875 get.  To use a DCI-compliant name, tick the <guilabel>Use DCI
876 name</guilabel> check-box.  The DCI name will be composed using details
877 of your content's soundtrack, the current date and other things that
878 can be specified in the DCI name details dialogue box, which you can
879 open by clicking on the <guilabel>Details</guilabel> button.
880 </para>
881
882 <para>
883 If the DCP name is long, it may not all be visible.  You can see the
884 full name by hovering the mouse pointer over the partial name.
885 </para>
886
887 <para>
888 The <guilabel>Container</guilabel> option sets the ratio of the image
889 in the DCP.  If this ratio is different to the ratio used for any
890 content, DCP-o-matic will pad the content with black.  In simple cases
891 this should be set to the same ratio as that for the the primary piece
892 of video content.  Alternatively, you might want to pillarbox a small
893 format into a Flat container: in this case, select the small format
894 for the content's ratio and &lsquo;Flat&rsquo; for the DCP.
895 </para>
896
897 <para>
898 Next up is the content type.  This can be
899 &lsquo;feature&rsquo;, &lsquo;trailer&rsquo; or whatever; select the
900 required type from the drop-down list.
901 </para>
902
903 <para>
904 The <guilabel>Frame Rate</guilabel> control sets the frame rate of
905 your DCP.  This can be a little tricky to get right.  Ideally, you
906 want it to be the same as the video content that you are using.  If it
907 is not the same, DCP-o-matic must resort to some tricks to alter your
908 content to fit the specified frame rate.  Frame rates are discussed in
909 more detail in <xref linkend="ch-frame-rates"/>.
910 </para>
911
912 <para>
913 The <guilabel>Encrypted</guilabel> check-box will set whether the DCP
914 should be encrypted or not.  If this is ticked, the DCP will require a
915 KDM to play back.  Encryption is discussed in <xref
916 linkend="ch-encryption"/>.
917 </para>
918
919 <para>
920 The <guilabel>Use best</guilabel> button sets the DCP video frame rate
921 to what DCP-o-matic thinks is the best given the content that you have
922 added.
923 </para>
924
925 <para>
926 The <guilabel>Audio Channels</guilabel> control sets the number of
927 audio channels that the DCP will have.  If the DCP has any channels
928 for which there is no content audio they will be replaced by silence.
929 </para>
930
931 <para>
932 The <guilabel>3D</guilabel> button will set your DCP to 3D mode if it
933 is checked.  A 3D DCP will then be created, and any 2D content will be
934 made 3D compatible by repeating the same frame for both left and right
935 eyes.  A 3D DCP can be played back on many 3D systems (e.g. Dolby 3D,
936 Real-D etc.) but not on a 2D system.
937 </para>
938
939 <para>
940 The <guilabel>Resolution</guilabel> tab allows you to choose the
941 resolution for your DCP.  Use 2K unless you have content that is of
942 high enough resolution to be worth presenting in 4K.
943 </para>
944
945 <para>
946 The <guilabel>JPEG2000 bandwidth</guilabel>; setting changes how big the final
947 image files used within the DCP will be.  Larger numbers will give
948 better quality, but correspondingly larger DCPs.  The bandwidth can be
949 between 50 and 250 megabits per second (MBps).
950 </para>
951
952 <para>
953 The <guilabel>Standard</guilabel> option specifies which of the two
954 DCP standards DCP-o-matic should use.  If in doubt, use SMPTE (the
955 more modern of the two).
956 </para>
957
958 <para>
959 Finally, the <guilabel>scaler</guilabel> is the method that will be used to scale up
960 your content to the required size for the DCP, if required.  Bicubic is a fine choice in
961 most situations.
962 </para>
963
964 </chapter>
965
966 <chapter xml:id="ch-encryption" xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
967 <title>Encryption</title>
968
969 <para>
970 It is not required that DCPs be encrypted, but they can be.  This
971 chapter discusses the basic principles of DCP encryption, and how
972 DCP-o-matic can create encrypted DCPs and KDMs for them.
973 </para>
974
975 <section>
976 <title>Basics</title>
977
978 <para>
979 DCPs can be encrypted.  This means that the picture and sound data are
980 encoded in such a way that only cinemas &lsquo;approved&rsquo; by the
981 DCP's creators can read them.  In particular, this means copies of the
982 DCP can be distributed by insecure means: if an ne'er-do-well called
983 Mallory obtains a hard drive containing an encrypted DCP, there is no
984 way that he can play it.  Only those cinemas who receive a key
985 delivery message (KDM) can play the DCP.
986 </para>
987
988 <section>
989 <title>How it works (in a nutshell)</title>
990
991 <para>
992 This section attempts to summarise how DCP encryption works.  You can
993 skip it if you like.  You may need some knowledge of encryption
994 methods to understand it.
995 </para>
996
997 <para>
998 We suppose that we are trying to distribute a DCP to
999 Alice's cinema, without a troublemaker called Mallory being able to
1000 watch it himself.
1001 </para>
1002
1003 <para>
1004 There are two main families of encryption techniques.  The first,
1005 symmetric-key encryption, allows us to encode some data using some
1006 numeric key.  After encoding, no-one can decode the data unless they
1007 know the key.
1008 </para>
1009
1010 <para>
1011 The first step in a DCP encryption is to encode its data with some key
1012 using symmetric-key encryption.  The encrypted DCP can then be sent
1013 anywhere, safe in the knowledge that even if Mallory got hold of a
1014 copy, he could not decrypt it.
1015 </para>
1016
1017 <para>
1018 Alice, however, needs to know the key so she can play the DCP in her
1019 cinema.  A simple approach might be for us to send Alice the key.
1020 However, if Mallory can intercept the DCP, he might also be able to
1021 intercept our communication of the key to Alice.  Furthermore, if Alice
1022 happened to know Mallory, she could just send him a copy of the key.
1023 </para>
1024
1025 <para>
1026 The clever bit in DCP encryption requires the use of public-key
1027 encryption.  With this technique we can encrypt a block of data using
1028 some &lsquo;public&rsquo; key.  That data can then only be decrypted
1029 using a <emphasis>different</emphasis> &lsquo;private&rsquo; key.  The
1030 private and public keys are related mathematically, but it is
1031 extremely hard (or rather, virtually impossible) to derive the private
1032 key from the public key.
1033 </para>
1034
1035 <para>
1036 Public-key encryption allows us to distribute the DCP's key to Alice
1037 securely.  The manufacturer of Alice's projector generates a public
1038 and private key.  They hide the private key deep inside the bowels of
1039 the projector (inside an integrated circuit) where no-one can read it.
1040 They then make the public key available to anyone who is interested.
1041 </para>
1042
1043 <para>
1044 We take our DCP's symmetric key and encrypt it using the public key of
1045 Alice's projector.  We send the result to Alice over email (using a
1046 format called a Key Delivery Message, or KDM).  Her projector then
1047 decrypts our message using its private key, yielding the magic
1048 symmetric key which can decrypt the DCP.
1049 </para>
1050
1051 <para>
1052 If is fine if Mallory intercepts our email to Alice, since the only
1053 key which can decrypt the message is the private key buried inside
1054 Alice's projector.  The projector manufacturer is very careful that
1055 no-one ever finds out what this key is.  Our DCP is secure: only Alice
1056 can play it back, since only her projector knows the key (even Alice
1057 does not).
1058 </para>
1059
1060 </section>
1061 </section>
1062
1063 <section>
1064 <title>Encryption using DCP-o-matic</title>
1065
1066 <para>
1067 There are two steps to distributing an encrypted DCP.  First, the
1068 DCP's data must be encrypted, and secondly KDMs must be generated for
1069 those cinemas that are allowed to play the DCP.
1070 </para>
1071
1072 <para>
1073 The first part is simple: ticking the <guilabel>Encrypted</guilabel>
1074 box in the <guilabel>DCP</guilabel> tab of DCP-o-matic will encrypt
1075 the DCP using a random key that DCP-o-matic generates.  The key will
1076 be written to the film's metadata file, so that should be kept
1077 secure.
1078 </para>
1079
1080 <para>
1081 A DCP that is generated with the <guilabel>Encrypted</guilabel> box
1082 ticked will not play on any projector as-is (it will be marked as
1083 &lsquo;locked&rsquo;, or whatever the projector manufacturer's term
1084 is).
1085 </para>
1086
1087 <para>
1088 The second part is to generate KDMs for the cinemas that you wish to
1089 allow to play your DCP.  This is done using the <guilabel>Make
1090 KDMs</guilabel> option on the <guilabel>Jobs</guilabel> menu.  This
1091 will open the KDM dialogue box, as shown in <xref linkend="fig-kdm"/>.
1092 </para>
1093
1094 <figure id="fig-kdm">
1095   <title>KDM dialog</title> 
1096   <mediaobject>
1097     <imageobject> 
1098       <imagedata fileref="screenshots/kdm&scs;"/>
1099     </imageobject> 
1100   </mediaobject>
1101 </figure>
1102
1103 <para>
1104 In order to generate KDMs for a particular projector, you need to know
1105 its <emphasis>certificate</emphasis>.  These are usually made
1106 available by the projector manufacturers as text files with a
1107 <code>.pem</code> extension.
1108 </para>
1109
1110 <para>
1111 DCP-o-matic can store these certificates to make life easier.  It
1112 stores details of cinemas and screens within those cinemas.  Each
1113 screen has a certificate for its projector.  DCP-o-matic can generate
1114 KDMs for any screens that it knows about.
1115 </para>
1116
1117 <para>
1118 To add a cinema, click <guilabel>Add Cinema...</guilabel>.  This opens
1119 a dialogue box into which you can enter the cinema's name, and
1120 optionally an email address.  This email address can be used to
1121 get DCP-o-matic to deliver KDMs via email, but it is optional.
1122 </para>
1123
1124 <para>
1125 Once you have added a cinema, select it by clicking on its name, then
1126 click <guilabel>Add Screen...</guilabel>.  The resulting dialogue
1127 allows you to enter a name for the screen and load in its certificate
1128 from a file.  The certificate should be in SHA256 PEM format.
1129 </para>
1130
1131 <para>
1132 Once you have set up all the screens that you need KDMs for,
1133 DCP-o-matic can generate KDMs for the last DCP that you generated for
1134 the currently-loaded film.  Select the cinemas and/or screens that you
1135 want KDMs for and fill in the start and end dates and times.  
1136 </para>
1137
1138 <para>
1139 Finally, choose what you want to do with the KDMs.  They can be
1140 written to disk, to a location that you can specify by clicking
1141 <guilabel>Browse</guilabel>.  Alternatively, if you choose
1142 <guilabel>Send by email</guilabel> the KDMs will be zipped up and
1143 emailed to the appropriate cinema email addresses.  Click OK to
1144 generate the KDMs.
1145 </para>
1146
1147 </section>
1148
1149 </chapter>
1150
1151
1152 <chapter xml:id="ch-preferences" xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
1153 <title>Preferences</title>
1154
1155 <para>
1156 DCP-o-matic provides a few preferences which can be used to modify its
1157 behaviour.  This chapter explains those options.
1158 </para>
1159
1160 <section>
1161 <title>The preferences dialogue</title>
1162
1163 <para>
1164 The preferences dialogue is opened by choosing
1165 <guilabel>Preferences...</guilabel> from the <guilabel>Edit</guilabel>
1166 menu.  The dialogue is split into four tabs.
1167 </para>
1168
1169 <section>
1170 <title>Miscellaneous</title>
1171
1172 <para>
1173 The miscellaneous tab is shown in <xref linkend="fig-prefs-misc"/>.
1174 </para>
1175
1176 <figure id="fig-prefs-misc"> 
1177   <title>Miscellaneous preferences</title> 
1178   <mediaobject>
1179     <imageobject> 
1180       <imagedata fileref="screenshots/prefs-misc&scs;"/>
1181     </imageobject> 
1182   </mediaobject>
1183 </figure>
1184
1185 <section>
1186 <title>Language</title>
1187
1188 <para>
1189 If you tick the <guilabel>Set Language</guilabel> checkbox and choose
1190 a language from the list, that language will be used for DCP-o-matic.
1191 You will need to restart DCP-o-matic to see the new language.
1192 </para>
1193
1194 <para>
1195 The translations for DCP-o-matic have been contributed by helpful
1196 users.  If your language is not on the last, head to <ulink
1197 url="http://dcpomatic.com/i18n.php">the DCP-o-matic website</ulink> to
1198 read about how to contribute a translation.
1199 </para>
1200 </section>
1201
1202 <section>
1203 <title>Threads</title>
1204
1205 <para>
1206 When DCP-o-matic is encoding DCPs it can use multiple parallel threads
1207 to speed things up.  Set this value to the number of threads
1208 DCP-o-matic should use.  This would typically be set to the number of
1209 processors (or processor cores) in your machine.
1210 </para>
1211
1212 </section>
1213
1214 <section>
1215 <title>Defaults</title>
1216
1217 <para>
1218 The next few options allow you to set up default values for several
1219 properties of new films that you create.
1220 </para>
1221
1222 </section>
1223 </section>
1224
1225 <section xml:id="sec-prefs-servers">
1226 <title>Encoding servers</title>
1227
1228 <para>
1229 The encoding servers tab is shown in <xref linkend="fig-prefs-servers"/>.
1230 </para>
1231
1232 <figure id="fig-prefs-servers"> 
1233   <title>Encoding servers preferences</title> 
1234   <mediaobject>
1235     <imageobject> 
1236       <imagedata fileref="screenshots/prefs-servers&scs;"/>
1237     </imageobject> 
1238   </mediaobject>
1239 </figure>
1240
1241 <para>
1242 If you have spare machines sitting around on your network not doing
1243 much, they can be pressed into service to speed up DCP encodes.  This
1244 is done by running a small server program on the machine, which will
1245 encode video sent to it by the &lsquo;master&rsquo; DCP-o-matic.  This
1246 option is described in more detail in <xref linkend="ch-servers"/>.
1247 Use these preferences to specify the encoding servers that should be
1248 used.
1249 </para>
1250
1251 </section>
1252
1253 <section>
1254 <title>Metadata</title>
1255
1256 <para>
1257 The metadata tab is shown in <xref linkend="fig-prefs-metadata"/>.
1258 </para>
1259
1260 <figure id="fig-prefs-metadata"> 
1261   <title>Metadata preferences</title> 
1262   <mediaobject>
1263     <imageobject> 
1264       <imagedata fileref="screenshots/prefs-metadata&scs;"/>
1265     </imageobject> 
1266   </mediaobject>
1267 </figure>
1268
1269 <para>
1270 This allows you to set up a couple of identifiers that are written
1271 into the DCP.  The default values should cause no problems.
1272 </para>
1273
1274 </section>
1275
1276 <section xml:id="sec-prefs-tms">
1277 <title>TMS</title>
1278
1279 <para>
1280 The TMS tab (shown in <xref linkend="fig-prefs-tms"/>) gives some
1281 options for specifying details about your theatre management system
1282 (TMS).  If you do this, and your TMS accepts SSH connections, you can
1283 upload DCPs directly from DCP-o-matic to the TMS using the
1284 <guilabel>Send DCP to TMS</guilabel> option in the
1285 <guilabel>Jobs</guilabel> menu.
1286 </para>
1287
1288 <figure id="fig-prefs-tms"> 
1289   <title>TMS preferences</title> 
1290   <mediaobject>
1291     <imageobject> 
1292       <imagedata fileref="screenshots/prefs-tms&scs;"/>
1293     </imageobject> 
1294   </mediaobject>
1295 </figure>
1296
1297 <para>
1298 <guilabel>TMS IP address</guilabel> should be set to the IP address of
1299 your TMS, <guilabel>TMS target path</guilabel> to the place that DCPs
1300 should be uploaded to (which will be relative to the home directory of
1301 the SSH user).  Finally, the user name and password are the
1302 credentials required to log into the TMS via SSH.
1303 </para>
1304 </section>
1305
1306
1307 </section>
1308 </chapter>
1309
1310 <chapter xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en" xml:id="ch-frame-rates">
1311 <title>Frame rates</title>
1312
1313 <para>
1314 In an ideal world, a DCP would be created using content at the same
1315 video frame and audio sampling rates as the DCP.  This is not,
1316 however, always possible.
1317 </para>
1318
1319 <section>
1320 <title>DCP rate limitations</title>
1321
1322 <para>
1323 There are some limitations to video and audio rates in DCPs.  This is
1324 complicated by the fact that not all projectors will play DCPs at the
1325 same rates.  It is possible to create a DCP which one projector will
1326 play fine, but another (of a different type) will refuse to play, or
1327 even refuse to ingest.
1328 </para>
1329
1330 <section>
1331 <title>Guaranteed rates</title>
1332
1333 <para>
1334 The only rates that are (pretty much) guaranteed to work on all DCI
1335 projectors is 24 frames per second (fps) for video and 48kHz or 96kHz
1336 for audio.  If you are sending your DCPs to unknown places it wise to
1337 consider using these rates if at all possible.
1338 </para>
1339
1340 </section>
1341
1342 <section>
1343 <title>Other often-supported rates</title>
1344 <para>
1345 Many projectors now in the wild support additional video frame rates:
1346 25, 30 and 48 fps.
1347 </para>
1348 </section>
1349
1350 <section>
1351 <title>Adapting content to fit the DCP rate</title>
1352
1353 <para>
1354 DCP-o-matic has a few tricks to allow you to use content that is not
1355 in one of the &lsquo;approved&rsquo; rates.
1356 </para>
1357
1358 <para>
1359 Audio is easy: DCP-o-matic can resample to 48kHz from any source rate
1360 with minimal loss in quality.
1361 </para>
1362
1363 <para>
1364 Video rate conversion is harder.  DCP-o-matic's basic strategy to deal
1365 with a non-supported content rate is to run it at the wrong speed, and
1366 to adjust the audio to keep it in sync.
1367 </para>
1368
1369 <para>Let us consider the example of a 25fps source for which you want
1370 to create a 24fps DCP.  DCP-o-matic will put the frames from the
1371 source directly into the DCP without modification, but will tell the
1372 projector to play them back at 24fps.  This means that the DCP's video
1373 will run slightly slower than the original.
1374 </para>
1375
1376 <para>
1377 If DCP-o-matic did nothing else, the result of this would be that the
1378 audio would be running at the original speed with the video running
1379 slowly.  Hence the audio would drift slowly out of sync.  To avoid
1380 this, DCP-o-matic also resamples the audio such that the projector
1381 will play it too fast by the same amount.  Hence it will sound
1382 slightly different but will remain in sync with the video.
1383 </para>
1384
1385 <para>
1386 For very low or high frame rates, DCP-o-matic can also skip or duplicate frames.
1387 </para>
1388
1389 </section>
1390 </section>
1391
1392 <section>
1393 <title>Setting up</title>
1394
1395 <para>
1396 The <guilabel>Frame Rate</guilabel> control in the
1397 <guilabel>DCP</guilabel> tab sets the video frame rate that the DCP
1398 will use.  Clicking <guilabel>Use best</guilabel> sets the rate to
1399 what DVD-o-matic thinks is the best for your content.  With this
1400 button, DCP-o-matic assumes that the whole range of frame rates (24,
1401 25, 30 and 48fps) are allowable.
1402 </para>
1403
1404 <para>
1405 After this, the <guilabel>Video</guilabel> tab for each piece of
1406 content will give a summary of what DCP-o-matic is doing with that
1407 content.
1408 </para>
1409
1410 </section>
1411
1412 </chapter>
1413
1414
1415 <chapter xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en" xml:id="ch-servers">
1416 <title>Encoding servers</title>
1417
1418 <para>
1419 One way to increase the speed of DCP encoding is to use more
1420 than one machine at the same time.  An instance of DCP-o-matic can
1421 offload some of the time-consuming JPEG2000 encoding to any number of
1422 other machines on a network.  To do this, one &lsquo;master&rsquo;
1423 machine runs DCP-o-matic, and the &lsquo;server&rsquo; machines run
1424 a small program called &lsquo;dcpomatic_server&rsquo;.
1425 </para>
1426
1427 <section>
1428 <title>Running the servers</title>
1429
1430 <para>
1431 There are two options for the encoding server;
1432 <code>dcpomatic_server_cli</code>, which runs on the command line, and
1433 <code>dcpomatic_server</code>, which has a simple GUI.  The command line
1434 version is well-suited to headless servers, especially on Linux, and
1435 the GUI version works best on Windows where it will put an icon in the
1436 system tray.
1437 </para>
1438
1439 <para>
1440 To run the command line version, simply enter:
1441 </para>
1442
1443 <programlisting>
1444 dcpomatic_server_cli
1445 </programlisting>
1446
1447 <para>
1448 at a command prompt.  If you are running the program on a machine with
1449 a multi-core processor, you can run multiple parallel encoding threads
1450 by doing something like:
1451 </para>
1452
1453 <programlisting>
1454 dcpomatic_server_cli -t 4
1455 </programlisting>
1456
1457 <para>
1458 to run 4 threads in parallel.
1459 </para>
1460
1461 <para>
1462 To run the GUI version on windows, run the &lsquo;DCP-o-matic encode
1463 server&rsquo; from the start menu.  An icon will appear in the system
1464 tray; right-click it to open a menu from whence you can quit the
1465 server or open a window to show its status.
1466 </para>
1467
1468 </section>
1469 <section>
1470 <title>Setting up DCP-o-matic</title>
1471
1472 <para>
1473 Once your servers are running, you need to tell your master
1474 DCP-o-matic instance about them.  Start DCP-o-matic and open the
1475 <guilabel>Preferences</guilabel> dialog from the
1476 <guilabel>Edit</guilabel> menu.  At the bottom of this dialog is a
1477 section where you can add, edit and remove encoding servers.  For each
1478 encoding server you need only specify its IP address and the number of
1479 threads that it is running, so that DCP-o-matic knows how many
1480 parallel encode jobs to send to the server.
1481 </para>
1482
1483 <para>
1484 Once this is done, any encodes that you start will split the workload
1485 up between the master machine and the servers.
1486 </para>
1487
1488 </section>
1489 <section>
1490 <title>Some notes about encode servers</title>
1491
1492 <para>
1493 DCP-o-matic does not mind if servers come and go; if a server
1494 disappears, DCP-o-matic will stop sending work to it, and will check
1495 it every minute or so in case it has come back online.
1496 </para>
1497
1498 <para>
1499 You will probably find that using a 1Gb/s or faster network will
1500 provide a significant speed-up compared to a 100Mb/s network.
1501 </para>
1502
1503 <para>
1504 Making changes to the server configuration in the master DCP-o-matic
1505 will have no effect while an encode is running; the changes will only
1506 be noticed when a new encode is started.
1507 </para>
1508
1509 </section>
1510
1511 </chapter>
1512
1513 <chapter xml:id="ch-files" xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
1514 <title>Generated files</title>
1515
1516 <para>
1517 DCP-o-matic generates a number of files as it makes a DCP.  <xref
1518 linkend="fig-file-structure"/> shows the files that might be generated
1519 after you have created a DCP for a film called &lsquo;DCP Test&rsquo;.
1520 </para>
1521
1522 <figure id="fig-file-structure"> 
1523   <title>Creating a new film</title> 
1524   <mediaobject>
1525     <imageobject> 
1526       <imagedata fileref="diagrams/file-structure&dia;"/>
1527     </imageobject> 
1528   </mediaobject>
1529 </figure>
1530
1531 <para>
1532 The <code>DCP Test</code> folder is the one that you specify when you
1533 select the <guilabel>New Film</guilabel> option from DCP-o-matic's
1534 menu.  Everything is stored inside this folder.
1535 </para>
1536
1537 <para>
1538 DCP-o-matic generates some working files as it goes along.  These are as follows:
1539 <itemizedlist>
1540
1541 <listitem><code>log</code> is a list of notes that DCP-o-matic makes as it goes
1542 along.  This can be useful for debugging purposes if something goes
1543 wrong.</listitem>
1544
1545 <listitem><code>metadata</code> stores the settings that you have made
1546 for this film: things like cropping, output format and so on.</listitem>
1547
1548 <listitem><code>video</code> is where DCP-o-matic writes the DCP's
1549 video data as it encodes it.</listitem>
1550
1551 <listitem><code>analysis</code> is used to keep the results of audio analysis runs.</listitem>
1552
1553 <listitem><code>info</code> contains details of each video frame that
1554 DCP-o-matic has written so far.  This is used when an encoding
1555 operation is interrupted and DCP-o-matic must resume it.</listitem>
1556 </itemizedlist>
1557 </para>
1558
1559 <para>
1560 Following this is the DCP itself:
1561 <code>DCP-TEST_EN-XX_UK-U_51_2K_CSY_20130218_CSY_OV</code>.  This
1562 contains some small XML files, which describe the DCP, and two large
1563 MXF files, which contain the DCP's audio and video data.  This folder
1564 (<code>DCP-TEST_EN-XX_...</code>) is what you should ingest, or pass
1565 to the cinema which is showing your DCP.
1566 </para>
1567
1568 </chapter>
1569
1570
1571 </book>