094674e56310c3cab75eb8ac59587e860c4bba45
[goodguy/cin-manual-latex.git] / parts / Configuration.tex
1
2 \chapter{Configuration, Settings and Preferences}%
3 \label{cha:configuration_settings_preferences}
4 \index{configuration}
5 \index{settings}
6 \index{preferences}
7
8 \begin{figure}[htpb]
9     \centering \includegraphics[width=0.9\linewidth]{settings.png}
10     \caption{Settings of default Preferences with the Appearance tab selected}
11     \label{fig:settings}
12 \end{figure}
13
14 The user's default settings, preferences, and other helpful files are retained across sessions in a hidden file, called \texttt{.bcast5}, in the user’s \texttt{\$HOME} directory. Initially when \CGG{} is launched there is an empty project and there are program default settings, and from then on the \texttt{.bcast5} directory will contain the settings that were set when quitting.  If you need to revert to the default settings, delete the \texttt{.bcast5} directory contents and restart \CGG{}.  Or you may want to rename it temporarily if you think you might want it back later.
15 Although the location defaults to \texttt{\$HOME/.bcast5}, you can use the \texttt{CIN\_CONFIG} variable to override this location.  For example:  \texttt{export CIN\_CONFIG=/tmp/.bcast5}  will use a temporary setup for testing purposes.  It is also useful for multiple users sharing the same home directory who would like to have different configuration/preferences settings data.  And if you are experiencing inexplicable errors or crashes in \CGG{}, they may be due to a problem with \texttt{.bcast5} in which case taking it out of the picture  can at least eliminate this as the cause. Another use case is if we want multiple installations of \CGG{}, for example one stable and one experimental, we can create the \texttt{.bcastX} folder externally and then set it as default with the option \textit{Index files go here} in \nameref{sub:index_file_section}.
16
17 Several ways exist to change \CGG{}’s operational characteristics.  A lot of variations can be made to  settings and preferences by using the \textit{Settings} pulldown from the main window and choosing \textit{Preferences}.
18
19 \section{Playback A / Playback B}%
20 \label{sec:playback_a_b}
21 \index{preferences!playback\_a\_b}
22
23 \CGG{} supports 2 separate preferences for the playback configuration.  \CGG{} can be operated in a single or dual screen configuration, both by using Xinerama or dual screen configuration of X windows.  It will take some setup using Xconfig to make this work.
24
25 The \texttt{Settings $\rightarrow$ Preferences} menu has \textit{Playback A and Playback B} tabs.  The target display and audio device configuration can be separate, to support up to 2 display and/or audio device stations.  The active configuration displays an asterisk (*) in its selection tab and the selected tab will be made active when OK is pressed.  For example: you may have a dual screen monitor system with the left screen showing the \CGG{} main window and the right screen showing the composer.  Another setup might use a monitor for the left screen and an HDTV as the right screen displaying the composer.  When a playback configuration is selected, the audio/video device configuration is switched to the playback selection.  The active playback setup can be changed through use of the menu pulldown of \texttt{Settings $\rightarrow$ Preferences} or via the remote control menu selection (see the section Remote Control for DVB for more detail). 
26
27 \subsection*{Yes, you can watch TV on \CGG{} instead of \CGG{} on TV.}%
28 \label{sub:watch_tv_on_cinelerra}
29
30 \begin{figure}[htpb]
31         \centering
32         \includegraphics[width=0.9\linewidth]{multi-screen01.png}
33         \caption{Multi-screen Playback example useful for watching \CGG{} run on the \textit{big screen}}
34         \label{fig:multi-screen01}
35 \end{figure}
36
37 Figure~\ref{fig:multi-screen01} shows partial window of \textit{*Playback A} selected and the second tab for \textit{Playback B}.  Note that on the bottom right of the window, \textit{Default B Display:} \index{default A/B display} is set to $:0.1$, representing the setting for Screen 1.  On the unseen \textit{Playback A} window, the \textit{Default A Display:} will be set to $:0.0$ meaning for Screen 0.  Otherwise, the default would be nothing there or just <empty>.
38
39 \subsection{Audio Out section}%
40 \label{sub:audio_out_section}
41
42 The audio drivers are used for both recording and playback. The Audio Out settings affect the outcome when you play sound on the timeline.
43
44 \begin{description}
45     \item[Playback buffer samples] \index{playback buffer samples} for playing audio, small fragments of sound are read from disk and processed sequentially. A larger value here causes more latency when you change mixing parameters but yields more reliable playback.  Some sound drivers do not allow changing of the fragment, so latency is unchanged no matter what the value. Since different stages of the rendering pipeline can change the rate of the incoming data, it would be difficult to disconnect the size of the console fragments from the size of the fragments read from disk.
46     \item[Audio offset (sec)] \index{audio offset} the ability to tell the exact playback position on Linux sound drivers is poor.  The audio offset allows users to adjust the position returned by the sound driver in order to reflect reality. The audio offset does not affect the audio playback or rendering at all. It merely changes the synchronization of video playback. The easiest way to set the audio offset is to create a timeline with one video track and one audio track. Expand the audio track and center the audio pan. The frame rate should be larger than $24 fps$ and the sampling rate should be greater than $32000$. The frame size should be small enough for your computer to render it at the full framerate. Highlight a region of the timeline starting at 10 seconds and ending at 20 seconds. Drop a gradient effect on the video track and configure it to be clearly visible. Drop a synthesizer effect on the audio and configure it to be clearly audible. Play the timeline from 0 and watch to see if the gradient effect starts exactly when the audio starts. If it does not, expand the audio track and adjust the nudge. If the audio starts ahead of the video, decrease the nudge value. If the audio starts after the video, increase the nudge value. Once the tracks play back synchronized, copy the nudge value to the audio offset value in preferences. Note: if you change sound drivers or Disable hardware synchronization, you will need to change the audio offset because different sound drivers are unequally inaccurate.
47     \item[View follows playback] \index{view follows playback} this causes the timeline window to scroll when the playback cursor moves. This can slow down the X Server or cause the timeline window to lock up for long periods of time while drawing the assets.
48     \item[Disable hardware synchronization] \index{disable hardware synchronization} most sound cards and sound drivers do not give reliable information on the number of samples the card has played. You need this information for synchronization when playing back video. This option causes the sound driver to be ignored and a software timer to be used for synchronization.
49     \item[Audio playback in realtime priority (root only)] for really old computers, this setting allows uninterrupted playback during periods of heavy load. It forces the audio playback to the highest priority in the kernel. Today, it is most useful for achieving very low latency between console tweaks and sound card output. You must be root to get real-time priority. Only experts might want to use this because it interferes with ordinary time-share scheduling and can lock up the system.  When this is enabled, audio gets the first shot and burns audio until audio lets go. To explain, there are 2 kinds of scheduling, \textit{time-sharing} which is the default, and \textit{real time} where the scheduled task must explicitly request scheduling to allow other tasks to execute.  Time-share interrupts when you use up your allocated time slice.  Realtime priority audio will execute audio decode until it finishes, which may slow down other types of processing like video decoding.  Most decoders use a policy that video may be downsampled to accommodate scheduling, but will never skip audio because it creates a much more obvious defect.  This feature helps to make sure audio gets priority over video during decode. Be sure to check apply in order for this feature to take effect.
50     \item[Map 5.1$\rightarrow$2] \index{audio!map 5.1:2} playback 5.1 $\rightarrow$ 2 driver downmix maps 6 tracks to 2 channels when checked, that is mixes $5.1$ down to stereo on the output device side.  This is different from the patchbay and menubar functions which reset the pan/mix levels of the input channels.  In this way, you can render $5.1$ media, and use stereo speakers to listen in the same session setup.  This downmix only occurs if the playback is $5.1$ (6 channels) and the device config is stereo (2 channels).
51     \item[Gain] \index{audio!gain} set audio gain to a different value than the default of $1.0$ This feature, device level gain, corrects for hardware conditions which some devices may need to be useful.  For example, you may need to increase the gain for a weak microphone or a noisy speaker, since it affects rendering when you crank up or down the audio via use of the patchbay.  With the audio H/W gain support, you have the ability to fine tune the audio volume by some numerical value for the scale.  You are adjusting the scaling of data into the audio driver -- H/W scaling is done before it goes into or out of the driver.  This is a one time linear multiplication of the sample values, and may offer better control than the logarithmic DB gain controls of the application.
52     \item[Audio driver] \index{audio!driver} there are many sound drivers for Linux. This allows selecting one sound driver and setting parameters specific to it. The currently available possibilities are listed next.
53     \begin{description}
54         \item[\textit{ALSA}] is the most common sound driver these days and supports almost all sound cards. ALSA
55         is frequently updated but is very stable.
56         \item[\textit{OSS}] was one of the first Linux sound drivers and has an open source implementation with many sound cards supported.
57         \item[\textit{OSS Envy24}] is the commercial version of OSS with a variant for $24 bit 96 KHz$ sound cards. This variant required changes to the way the sound drivers were used and so needed a different driver.
58         \item[\textit{Raw 1394, DV 1394, IEC 61883}] are older audio drivers used by camcorders and not much else.
59         \item[Pulseaudio] Extends the functionality of ALSA. It is a more modern and highly supported driver.
60     \end{description}
61     \item[Device] \index{audio!device} with the down arrow, you can see the device choices on your computer.
62     \item[Bits] 8, 16 or 24 Bit Linear are the current choices for the number of bits of precision \CGG{} should set the device for. The meaning of the number of bits can be misleading. Some sound drivers need to be set to 32 bits to perform 24 bit playback and will not play anything when set to 24 bits. Other sound drivers need to be set to 24 bits for 24 bit playback.
63     \item[Stop playback locks up] this ALSA only checkbox is needed if stopping playback causes the software to lock up.  This has worked some time ago, but may no longer work as expected
64 \end{description}
65
66 \subsection{Video Out section}%
67 \label{sub:video_out_section}
68
69 The video drivers are used for video playback in the compositor and the viewer.  These determine how you will see video on the timeline.
70
71 \begin{description}
72     \item[Play every frame] \index{play every frame} this causes every frame of video to be displayed even if it means that the playback of the video tracks fall behind. Most likely you will want this enabled because, after all, in order to edit you want to see each frame.  However, if you are just watching a big video, you can switch to not play every frame so that you can at least not be distracted by slowness.
73     \item[Framerate achieved] \index{framerate achivied} the number of frames per second being displayed during playback. This is updated during playback only.  The goal is to get as close to the frame rate as possible, even if Play every frame is not enabled.
74     \item[Scaling equation] \index{scaling equation} Enlarge / Reduce -- this algorithm is used when video playback involves scaling or translation (only X11 video driver). This does not affect $1:1$ playback.  Choices available are:
75     \begin{description}
76         \item[\textit{Nearest Neighbor / Nearest Neighbor}] low quality output with fast playback. Often produces jagged edges and uneven motion.
77         \item[\textit{Bicubic / Bicubic}] Bicubic interpolation is used for both enlarging and reducing, enlarging blurs slightly but does not show stair step artifacts.
78         \item[\textit{Bicubic / Bilinear}] High quality output with slow playback. Bicubic interpolation is used for enlarging, which blurs slightly but does not show stair step artifacts. A bilinear interpolation is used for reduction, which produces very sharp images and reduces noise. Bilinear reduced images can be sharpened with a sharpen effect with less noise side effects than a normal sized image.
79         \item[\textit{Bilinear / Bilinear}] when slight enlargement is needed, a bilinear enlargement looks better than a bicubic enlargement.  Bilinear uses less CPU than either Bicubic or Lanczos.
80         \item[\textit{Lanczos / Lanczos}] is not necessarily a general purpose upscaler, but is intended for low resolution sources. However many people like the sharpening effects.  More quality from Lanczos does take more CPU.
81     \end{description}
82     \item[DVD subtitle to display] DVD IFO files usually contain subtitle tracks. These must be decoded with the MPEG decoder. Select Enable subtitles to enable subtitle decoding. There are usually multiple  subtitle tracks indexed by number and starting from 0. Enter the index number of the subtitle track to be decoded in the \textit{DVD Subtitle to display} text box or use the tumbler to increase the index value. Go to the asset corresponding to the MPEG file in the \textit{Resources} window and right click. Click on \textit{Info}. The number of subtitle tracks is shown at the bottom.
83     \item[Enable subtitles/captioning] for broadcast TV ??
84     \item[Label cells] ??
85     \item[TOC Program No] Table of Contents program number used in DVB ??
86     \item[Interpolate CR2 images] enables interpolation of CR2 images. Interpolation is required since the raw image in a CR2 file is a Bayer pattern. The interpolation uses dcraw's built-in interpolation and is very slow. This operation can be disabled and the Interpolate Pixels effect used instead for faster previewing
87     \item[White balance CR2 images] this enables white balancing for CR2 images if interpolation is also enabled. This is because proper white balancing needs a blending of all 3 primary colors. White balance uses the camera's matrix which is contained in the CR2 file.  Disabling white balancing is useful for operations involving dark frame subtraction. The dark frame and the long exposure need to have the same color matrix.  If you disable Interpolate CR2 Images and use the Interpolate Pixels effect, be aware the Interpolate Pixels effect always does both interpolation and white balancing using the camera's matrix, regardless of the settings in Preferences. Dark frame subtraction needs to be performed before Interpolate Pixels.
88     \item[Video driver] \index{video!driver} normally video on the timeline goes to the compositor window during both continuous   playback and when the insertion point is repositioned. Instead of sending video to the Compositor window, the video driver can be set to send video to another output device during continuous playback. However, this does not affect where video is routed when the insertion point is repositioned. Options are listed next.
89     \begin{description}
90         \item[\textit{X11}] this was the first method of graphical display on Unix systems. It just writes the RGB triplet for each pixel directly to the window. It is useful when graphics hardware can not handle very large frames.  And when X11 is usled with the associated checkbox enabled of \textit{use direct x11 render if possible} it can be a really good playback method to speed up playback for large frames.
91         \item[\textit{X11-XV}] this was an enhancement to X11 in 1999. It converts YUV to RGB in hardware with scaling. In some cases it may be the preferred playback method, but it can not handle large frame sizes. Maximum video size for XV is usually $1920\times1080$.
92         \item[\textit{X11-OpenGL}] the most powerful video playback method is OpenGL. With this driver, most effects are done in hardware with the graphics board installed in the computer. OpenGL allows video sizes up to the maximum texture size, which is usually larger than what XV supports, depending on the graphics driver.  OpenGL relies on PBuffers and shaders to do video rendering.  Plugins or transitions that do not  have \textit{handle OpenGL} in the code will use software instead of hardware and this will slow down playback.       
93         OpenGL does not affect rendering. It just accelerates playback.  X11-OpenGL processes everything in 8 bit color models, although the difference between YUV and RGB is retained. The scaling equation set in the preferences window is ignored by OpenGL -- it always uses linear scaling. Camera and projector operations use OpenGL, but some of the effects may not support OpenGL acceleration.
94         \item[\textit{Raw 1394, DV 1394, and IEC 61883}] are for old camcorders.
95     \end{description}
96     \item[Default A/B Display] the interface is intended for dual monitor displays. Depending on the value of Display, the Compositor window will appear on a different monitor from the rest of the windows.
97 \end{description}
98
99 \section{Recording}%
100 \label{sec:recording}
101 \index{preferences!recording}
102
103 The parameters here expedite the \texttt{File $\rightarrow$ Record}\dots function by allowing the user to pre-configure the file format and the hardware used for recording, since the hardware generally determines the supported file format. Once set, the file format is applied to all recordings.
104
105 \subsection{File Format section}%
106 \label{sub:file_format_section}
107
108 \begin{description}
109     \item[File Format] \index{file format} this determines the output file format for recordings. It depends heavily on the type of driver used. The menu selections are the same as those of the rendering interface.
110     \item[Record audio tracks] \index{record audio tracks} toggle must be enabled to record audio.
111     \item[Record video tracks]\index{record video tracks} toggle must be enabled to record video. The wrench \index{wrench} button left of both the audio and video tracks toggle, opens a configuration dialog in order to set the compression scheme (codec) for each audio and video output stream. The audio and video is wrapped in a container format defined by the \textit{File Format} menu. Different wrappers may record audio only, video only, or both.  Some video drivers can only record to a certain container. If the video driver is changed, the file format may be updated to give the supported output. If you change the file format to an unsupported format, it may not work with the video driver.
112     \item[Realtime TOC] setup for DVB recording to automatically generate a Table of Contents. This will scan the stream data \textit{on the fly} on its way to being written while the asset is being captured. ??
113 \end{description}
114
115 \subsection{Audio In section}%
116 \label{sub:audio_in_section}
117
118 \begin{description}
119     \item[Record Driver] \index{audio!record driver} is used for recording audio in the Record window. It may be configured the same as the Record Driver for video if the audio and video are wrapped in the same stream. Available parameters vary depending on the driver.  The drivers are the same as described in Playback A/B with the addition of DVB and V4L2 MPEG but no Raw 1394.
120     \item[DVB Adapter] name of a suitable DVB adapter for linux that is usb connected to your computer and has a connected broadcast TV antenna.??
121     \item[dev] your DVB adapter device number, which is usually 0.
122     \item[Bits] same as described in Playback A/B audio section.
123     \item[Follow audio config] ??
124     \item[Samples read from device] \index{sample read from device} a good value is $2048$ or approximate dev buffer size ($2k-16k$ probably).
125     Samples to write to disk -- at a time. First, audio is read in small fragments from the device. Then, many small fragments are combined into a large fragment before writing to disk. The disk writing process is done in a different thread. The value here determines how large the combination of fragments is for each disk write.  A good starting value is $48000$ but this will will most likely automatically change, probably to $44100$ if necessary.
126     \item[Sample rate for recording] \index{samples read from recording} regardless of what the project settings are, the value set here will be the sample rate used for recording. The sample rate should be set to the highest value the audio device supports.
127     \item[Channels to record] usually set to 2.
128     \item[Map 5.1$\rightarrow$2] \index{audio!map 5.1:2} eave unchecked to record all possible channels.
129     \item[Gain] \index{audio!gain} usually leave at default of $1.0$, but this device level gain corrects for hardware conditions on some devices which need  help.  This gives you the ability to fine tune the audio volume by some numerical value for the scale.  It is useful as better explained for the Gain in the Playback A/B Audio section discussed previously.
130     \item[Record in realtime priority] (root only) -- only experts might want to use this because it interferes with ordinary time-share scheduling and can lock up the system.  When this is enabled, audio gets the first shot and burns audio until audio lets go.
131 \end{description}
132
133 \subsection{Video In section}%
134 \label{sub:video_in_section}
135
136 \begin{description}
137     \item[Record driver] \index{video!record driver} used for recording video in the Record window. It may be configured the same as the Record Driver for video if the audio and video are wrapped in the same container. Available parameters vary depending on the driver. The drivers available are as follows.
138     \begin{itemize}
139         \item Video4Linux2
140         \item JPEG webcam
141         \item YUYV webcam
142         \item Video4Linux2 JPEG
143         \item Video4Linux2 MPEG
144         \item Screencapture
145         \item DV1394
146         \item IEC61883
147         \item DVB
148     \end{itemize}
149     \item[DVB Adapter] name of a suitable DVB adapter for linux that is usb connected to your computer and has a connected broadcast TV antenna.??
150     \item[dev] your DVB adapter device number, which is usually 0.
151     \item[Follow video config] ??
152     \item[Frames to record to disk at a time] frames are recorded in a pipeline. First, frames are buffered in the device. Then, they are read into a larger buffer for writing to disk. The disk writing is done in a separate thread from the device reading. For certain codecs the disk writing uses multiple processors. The value set here determines how many frames are written to disk at a time.
153     \item[Frames to buffer in device ] the number of frames to store in the device before reading and this determines how much latency there can be in the system before frames are dropped.
154     \item[Positioning] if set to \textit{Software timing}, use software for positioning information. Video uses audio for synchronization, but most sound cards do not give accurate position information so selecting this option makes \CGG{} calculate an estimation of audio position in software instead of hardware for synchronization.  You can also choose \textit{Presentation Timestamps}, \textit{Device Position}, or \textit{Sample Position}.
155     \item[Sync drives automatically] for high bitrate recording, the disk drives you use may be fast enough to store the data but your operating system may wait several minutes and stall as it writes several minutes of data at a time. This forces the operating system to flush its buffers every second instead of every few minutes to produce slightly better real-time behavior.
156     \item[Size of captured frame] is the size of the recorded frames in pixels. It is independent of the project frame size because most video devices only record a fixed frame size.
157     \item[Frame rate for recording ] the frame rate recorded is different from the project settings. This sets the recorded frame rate.
158 \end{description}
159
160 \section{Performance}%
161 \label{sec:performance}
162 \index{preferences!performance}
163
164 \subsection{Performance section}%
165 \label{sub:performance_section}
166
167 The main focus of the performance section is rendering parameters not available in the rendering dialog with the obvious gain of perhaps better performance.
168
169 \begin{description}
170     \item[Cache size] \index{cache size} to speed up rendering, several assets are kept open simultaneously. This determines how     many are kept open. A number too large may exhaust your memory rapidly. A number too small may result in slow playback as assets need to be reopened more frequently.
171     \item[Seconds to preroll renders] \index{pre-roll} some effects need a certain amount of time to settle in. Checking this option sets a number of seconds to render without writing to disk before the selected region is rendered. When using the render farm, you will sometimes need to preroll to get seamless transitions between the     jobs. Every job in a render farm is prerolled by this value. This does not affect background rendering because background rendering uses a different preroll value.
172     \item[Force single processor use] \index{force single processor} \CGG{} tries to use all processors on the system by default, but sometimes you will only want to use one processor, like in a render farm client. This forces only one processor to be used.  The operating system usually uses the second processor for disk access. The value of this parameter is used in render farm clients.
173     \item[Project SMP cpus ] \index{entry}SMP cpus to restrict the number of processors utilized, change the count number.  This number will be used for the plugin per load balance operation cpu limit, which uses smp-cpus to stripe your data. It does not affect the number of cpus used in any other \CGG{} operation besides plugins. On large cpu systems, it can come in handy to downgrade the number of cpus used for some plugins; otherwise it uses all of the processors and splits up the program into too many pieces which may add
174     considerable overhead in high cpu count systems.
175 \end{description}
176
177 \subsection{Background Rendering section}%
178 \label{sub:background_rendering_section}
179
180 \begin{description}
181     \item[Use background rendering] \index{background rendering!use} checking this box, enables automatic background rendering.  This works in conjunction with the interactive function \texttt{Settings menu $\rightarrow$ Toggle background rendering} which sets the point where background rendering starts up to the position of the insertion point.
182     \item[Frames per background rendering job] \index{frame per job} his only works if a render farm is being used; otherwise, background rendering creates a single job for the entire timeline. The number of frames specified here is scaled to the relative CPU speed of rendering nodes and used in a single render farm job.
183     \item[Frames to preroll background] \index{frame per pre-roll} the number of frames to render ahead of each background rendering job. Background rendering is degraded when preroll is used since the jobs are small. When using background rendering, this number is ideally 0. Some effects may require 3 frames of preroll.
184     \item[Output for background rendering] \index{background rendering!output} background rendering generates a sequence of image files in a certain directory. This parameter determines the filename prefix of the image files. It should be on a disk, accessible to every node in the render farm by the same path.
185     \item[File format] \index{file format} the file format for background rendering has to be a sequence of images. The format of the image sequences determines the quality and speed of playback. JPEG is a good choice usually.
186     \item[Video wrench] \index{wrench} this has the single option of \textit{use alpha}.  It is by default unchecked.
187 \end{description}
188
189 \subsection{Render Farm section}%
190 \label{sub:render_farm_section}
191
192 In the Render Farm Section are many options that are explained in detail in the \hyperref[sec:render_farm_usage]{Rendering} chapter of this manual.  Just make sure if you do not intend to use a render farm, that \textit{Use render farm} is not checked.
193
194 \section{Interface}%
195 \label{sec:interface}
196 \index{preferences!interface}
197
198 \subsection{Editing section}%
199 \label{sub:editing_section}
200
201 \begin{description}
202     \item[Clicking on edit boundaries] \index{trim} (trimming) \CGG{} not only allows you to perform editing by dragging edit boundaries, but also defines five separate operations that occur when you drag an edit boundary. Here you can select the behavior of each mouse button. The usage of each editing mode is described in great detail in the \hyperref[sub:split_view_compositor_using_drag_trim]{Advanced Editing} chapter.
203     \item[Keyframe reticle] \index{keyframe reticle} the options are \textit{Newer}, \textit{Dragging}, or \textit{Always}. This is used to help in checking edit alignment across tracks.  Always renders a line over all plugins, and dragging only over the drag icon. Never draws nothing.
204     \item[Snapshot path] \index{snapshot!path} designates the default directory path for snapshot and grabshot generated output.
205 \end{description}
206
207 \subsection{Operation section}%
208 \label{sub:operation_section}
209
210 \begin{description}
211     \item[Probe Order] \index{probe order} clicking on this box brings up a popup allowing you to change the probe order usually for media that is raw camera output but it is also helpful if you want to ensure that a specific driver is used for certain media; for example you may want \textit{tiff} files to be read natively instead of by ffmpeg.
212     \item[trap sigSEGV] always enable this so that if \CGG{} crashes, a dump will be generated for analysis.
213     \item[trap sigINT] always enable this so that you can use Ctrl-c to interrupt the program if it appears to be hanging.  This will often generate some useful information for analysis.
214     \item[Use yuv420p dvd interlace format] \index{DVD!yuv420p interlace mode} for DVD media this option maintains the interlacing in Chroma sample addressing, which ordinarily would be deleted because the upsampling of interlaced chroma fields is normally done using a progressive algorithm.  With this mode enabled, the MPEG decoder uses a different algorithm for interlaced frames so that the 4:2:0 format chroma interlacing is preserved.
215     \item[Min / Max DB for meter] \textit{Min DB} is useful because some sound sources have a lower noise threshold than others. Everything below the noise threshold is meaningless. This option sets the meters to clip below a certain level.  \textit{Max DB} sets the maximum sound level represented by the sound meters. This value is presented merely to show how far over the limit a sound wave is. No matter what this value is, no sound card can play sound over 0 dB.
216     \item[Import images with a duration of \# seconds] when you load single images, like \textit{png} or \textit{jpeg}, automatically load for \# number of seconds.  This makes it easier to see an image on the timeline.  If you just want the single frames, uncheck this option.
217     \item[Auto start lv2 gui] \index{LV2 gui} some lv2 plugins display a \textit{glitzy} UI (User Interface); for example the Calf plugins.  For these LV2 plugins, if you want that to automatically come up without having to click on the UI button on the simplified ui interface, this is the flag to enable that.
218     \item[Android Remote Control] check this to enable using an android device as a remote control for broradcast TV.
219     \item[Port] default port 23432 is used for the android remote control.
220     \item[Pin] default PIN Cinelerra is used for the android remote control.
221     \item[Shell Commands] \index{shell commands} this button brings up the controls for setting up your own shell commands or editing previously set up commands.  See the section on Menu Bar Shell Commands for information.
222     \item[Reload plugin index] \index{plugins!reload index} execute this reload command when you have modified plugins and want to make sure your changes take effect.
223     \item[Nested Proxy Path] \index{nested proxy path} designates the default directory path for Nested Proxy files.
224     \item[Default LV2\_Path] \index{default lv2 path} when there is no system \texttt{LV2\_PATH} set, if you want lv2 plugins loaded, you must set the correct directory path name here. When you change this field, cin will automatically restart and load the newly specified lv2 plugins.
225 \end{description}
226
227 \subsection{Index Files section}%
228
229 \label{sub:index_file_section}
230 Screencast below shows part of the Preferences menu where you can change the index files setup (figure~\ref{fig:index}).
231 \begin{figure}[htpb]
232     \centering
233     \includegraphics[width=1.0\linewidth]{images/index-01.png}
234     \caption{Index file setup for your preferred configuration for Render Farm sharing or anything}
235     \label{fig:index}
236 \end{figure}
237
238 \begin{description}
239     \item[Index files go here] \index{index file!path} index files exist in order to speed up drawing the audio/video tracks. This option determines where index files are placed on the disk.
240     \item[Size of index file] \index{index file!size} determines the size of an index file. Larger index sizes allow smaller files to be drawn faster, while slowing down the drawing of large files. Smaller index sizes allow large files to be drawn faster, while slowing down small files.  The default is currently 4kB for average size files.
241     \item[Number of index files to keep] \index{index file!number} to keep the index directory from becoming very large, old index files are deleted. This determines the maximum number of index files to keep in the directory.
242     \item[build ffmpeg marker indexes] \index{ffmpeg!build index} improves ffmpeg seeks in certain cases although not clear which ones.
243     \item[Scan for commercial during toc build] used for working with broadcast TV commercial removal.
244     \item[Delete existing indexes] \index{index file!delete} when you change the index size or you want to clean out excess index files, this deletes all the index files.
245     \item[Delete clip thumbnails] \index{delete clip thumbnails} as clip thumbnails accumulate over time, you may want to delete them to get the disk space back.
246 \end{description}
247
248 \section{Appearance}%
249 \label{sec:appearance}
250 \index{preferences!appearance}
251
252 \subsection{Layout section}%
253 \label{sub:layout_section}
254
255 \paragraph{Theme} \index{theme} \CGG{} supports 11 different themes to suit the preferences of different
256 users (figure~\ref{fig:theme}).  When you change the theme, \CGG{} automatically saves your
257 session and restarts exactly where you were.  The \textit{Themes User Interface} are described
258 in more detail next.  \textit{Akirad} themes are all available in Cin-GG as designed by the
259 \textit{Cinecutie} project.  They provide alternative User Interface environments allowing
260 you to choose your favorite look.  Be aware that when you change your theme, \CGG{} will
261 automatically shutdown and restart for it to take effect.  The theme you choose is preserved
262 across sessions.
263
264 \underline{Theme choices available:}
265
266 \begin{itemize}[noitemsep]
267     \item Blond
268     \item Blond-cv
269     \item Blue
270     \item Blue Dot
271     \item Bright
272     \item Cakewalk (default)
273     \item Hulk
274     \item Neophyte
275     \item Pink Lady
276     \item S.U.V.
277     \item UnFlat
278 \end{itemize}
279
280
281 \begin{figure}[htpb]
282     \centering \includegraphics[width=0.9\linewidth]{theme.png}
283     \caption{Shows the Cakewalk theme (courtesy Olaf) on Preferences window with list of themes}
284     \label{fig:theme}
285 \end{figure}
286
287
288 \underline{How To Change your Theme:}
289
290 To change a \textit{Theme} in the main window pulldown, select:
291
292 \texttt{Settings $\rightarrow$ Preferences};
293
294 then in Preferences window, click on the \textit{Appearance} tab. In the Editing section in the lower left hand corner, click on the \textit{down arrow} next to Theme to see your choices. Click on your desired choice from the list given. Check OK, \CGG{} will automatically shutdown and restart.
295
296 To create a personal theme see \hyperref[sec:how_create_theme]{How to create your own theme}.
297
298 \paragraph{Plugin Icons} \index{plugins!icons} There are currently 4 choices for different plugin icons to include the old original.
299 \paragraph{Locale} \index{locale/language} The default is \textit{sys} so that the system language is active. With the pulldown menu we can choose among the other languages present in ... This language will be saved in
300 your Configuration and used each time you start up CinGG. In order to change the environment variable, LANGUAGE, the setting must be \textit{sys} because that is the best way we could get it working.
301 \paragraph{Layout Scale} \index{layout scale} Allows for setting up scaling for your 4K monitors or any monitor where you would like the text and icons to be just a little bigger or a lot bigger. This scale setting is automatically saved across sessions. 
302 When first using \CGG{}, or if \textit{Layout Scale} has never been set, the initial value is 0.0.
303 This means an automatic probe of the biggest monitor in use will be used for the setting. The advantage of this is that "new users" with a 4K monitor will not immediately be discouraged with too small text/icons.
304 Leaving it at 0 instead of 1 is what most people will do and is probably preferable so that if you move to a different monitor with different dimensions/resolution, it will automatically probe. 
305 If a user wants to prevent the automatic scaling, \textit{Layout Scale} should be set to 1.0 to avoid the smaller characters that might result due to the probe of a non-1080p monitor.
306
307 For testing or when you are using a different sized monitor and want to ensure the expected
308 size for larger text/fonts before you start the application from a window, you can keyin:
309 \begin{lstlisting}[numbers=none]
310         BC_SCALE=2.0 {your Cinelerra path}/bin/cin
311 \end{lstlisting}
312 The scaling size would only be in effect for that run of \CGG{}.  This is particularly
313 useful in the case where the user makes a mistake in setting the \textit{Layout Scale} and \CGG{} becomes unusable. 
314 Then the environment variable, BC\_SCALE, can be used to overcome the bad setting so that you can get back into
315 \CGG{} and fix the scaling parameter.  For example, if you 
316 accidentally set \textit{Layout Scale} to 112.6, keyin the following 
317 and then when you get back into \CGG{}, fix \textit{Layout Scale} value in Preferences.  
318 \begin{lstlisting}[numbers=none]
319         BC_SCALE=1.0 {your Cinelerra path}/bin/cin
320 \end{lstlisting}
321 \paragraph{View thumbnail size} \index{view thumbnais size} You can increase or decrease the thumbnail size -- larger size uses more cpu.
322 \paragraph{Vicon quality} \index{vicon!quality}  Increase the quality used for thumbnails to get more clarity of pixels -- this will use more memory.
323 \paragraph{Vicon color mode} \index{vicon!color mode} Modify the color mode to Low, Medium, or High for the thumbnails -- High will look the best but takes more memory.
324
325 \subsection{Time Format section}%
326 \label{sub:time_format_section}
327 \index{timebar}
328
329 Various representations of time are given so that you can select the most convenient one for you. The time representation can also be changed by Ctrl-clicking on the timebar in the main window.
330
331 \begin{itemize}[noitemsep]
332     \item Hours : Minutes : Seconds : xxx
333     \item Hours : Minutes : Seconds : frames
334     \item Timecode
335     \item Samples
336     \item Hex Samples
337     \item Frames
338     \item Feet-frames  [frames per foot \dots]
339     \item Seconds
340 \end{itemize}
341
342 \subsection{Color section}%
343 \label{sub:color_section}
344
345
346 \paragraph{Highlighting Inversion color} \index{inverted colors} Modify the selection area color; default is \textit{ffffff} which is white. When you make a selection, that area becomes an inverse image which by default becomes a whitish color.  You can set it to a different color by modifying the hex value in the box next to \textit{Highlight inversion color}.   Keep in mind that if you set the value to a low value, you will not be able to see the outlined selected area (for example the hex value "f" is not readily visible and leads to confusion).  A leading 0 or blank is not allowed and will be automatically changed to \textit{ffffff}.
347 \paragraph{Composer BG Color} \index{background color} You can choose the background color of the viewer window.
348 \paragraph{YUV color space} \index{yuv color space} Default is \textit{BT601}; others \textit{BT709} (high definition), \textit{BT2020} (ultra high definition).
349 \paragraph{YUV color range} \index{yuv color range} JPEG [$0-255$] and MPEG [$16-235$]
350
351
352 \subsection{Warnings section}%
353 \label{sub:warnings_section}
354
355 \begin{description}
356         \item[ffmpeg probe warns rebuild indexes] \index{warnings!ffmpeg probe} this warning is very important for switching from using ffmpeg to using native formats, such as in the case of MPEG, so that you are reminded to \textit{rebuild indexes}.  If you do not rebuild the indexes, seeking on the timeline back and forth could very well be problematic, meaning it might not go to the right place.  Notification about rebuilding the indexes will appear by default as shown in the figure~\ref{fig:ff_probe} when you click on the FF icon in the main timeline in the upper right hand corner.  Once you click on \textit{Don’t show this warning again} you will no longer be warned and this flag will no longer be enabled.
357         \begin{figure}[htpb]
358                 \centering \includegraphics[width=0.9\linewidth]{ff_probe.png}
359                 \caption{Default warning when you click on FF icon in main window}
360                 \label{fig:ff_probe}
361         \end{figure}
362         \item[EDL version warns if mismatched] \index{warnings!EDL version} in the case of a Batch Render, it is often helpful to be warned if the EDL has been changed so that you are aware that what is going to be rendered is different than your current EDL session.
363         \item[Create Bluray warns if not root] \index{warnings! bluray no root} if checked and you are not logged in as root, you will get an error message in order to avoid doing a lot of work and then failing out because root is required for automount and to write on DVD hardware.
364         \item[Warn on creating file references] \index{warnings! file by reference} if checked, you will always be warned when using "File by 
365         Reference", that is when an EDL is opened as \textit{Reference}.  This is best left checked to ensure that you are aware of the fact that when changes are made to this file and rendered, any other uses of the same file will be affected and modified also.  
366 \end{description}
367
368 \subsection{Dangerous section}%
369 \label{sub:dangerous_section}
370
371 \begin{description}
372         \item[Unsafe GUI in batchrender] It serves to hide the button \textit{Save to EDL Path} present in the Batch Render window. In fact if used accidentally, it could lead to the loss of the original EDL content, which is overwritten without changing the project name. See Batch Rendering, section \nameref{sub:advanced_features}.
373         \item[Autosave continuous backups] For each editing action \CGG{} creates an automatic backup. To avoid excessive creation, this option limits their number to 50 when quitting out of the program.
374 \end{description}
375
376 \subsection{Flags section}%
377 \label{sub:flags_section}
378
379 This section contains many useful options to cater to the various preferences of individual users.
380
381 \begin{description}   
382     \item[Autocolor assets] \index{autocolor assets} to make it visually easier to see your clips on the timeline that are from the same media file, you can have them automatically colored. Use of this feature requires additional memory and cpu on every timeline redraw, therefore smaller computers may not want this checked on.
383     \item[Perpetual session] \index{perpetual session} is very useful for working on a project over many days so you can just quit before
384     shutting down and the next time you start up \CGG{} you will be right back where you left off. You
385     will retain all of your undo's and redo's.
386     \item[Timeline Rectify Audio] \index{timeline rectify audio} for displaying rectified audio on the timeline instead of a standard audio waveform, check this flag.  The waveform is cut on the zero line, thus making the silent areas more visible and the waveform is stretched more over the entire height of the audio track, which improves the visibility of certain areas. This only affects the timeline and not any other audio waveform displays.
387     \item[Clears before toggle] \index{clears before toggle} when using copy/paste in drag and drop mode some users prefer to resort to the addition of the Ctrl key for adding multiple selections.  By checking this flag, the user retains usage as is commonly done for listbox operations.
388     \item[Always show next frame] \index{always show next frame} in this mode the insertion pointer reflects the same as the Compositor so that for playing forward, the result is what looks like 1 was added to the frame displayed in the Compositor window.  This is fully explained in another section (\nameref{sub:playing_seeking}).
389     \item[Show tip of the day] if checked, a tip will be displayed in a popup box when start up \CGG{}.
390     \item[Use thumbnails in resource window] \index{use thumbnails in resources window} the Resource Window displays thumbnails of assets by default, but drawing asset thumbnails can take more time and CPU so you may want to uncheck this.   
391     \item[Popups activate on button up] \index{popups activate on button up} this is the default but if unchecked, popups activate on button down.
392     \item[Set Input Focus when window entered] \index{set input focus} this is checked on by default because on some operating system distros, when you move your mouse to a different window, nothing happens and you are left wondering why you can not enter information.  When checked this causes the input focus to shift to any \CGG{} window when the cursor enters an exposed region of the window which eliminates the need to switch input focus by tabbing. 
393     \item[Click to activate text focus] \index{click to activate text focus} Click to activate text focus
394     \item [Click to deactivate text focus] \index{click to deactivate text focus} if checked, you will have to click to deactivate text focus.
395     \item [Auto rotate ffmpeg media] \index{auto rotate ffmpeg media} this is the default setting so that your media will automatically be rotated when there is metadata in the file with a rotation value.  Especially useful for cell phone.    
396 \end{description}
397
398 \section{About}%
399 \label{sec:about}
400 \index{preferences!about}
401
402 This section gives you information about the \CGG{} program and version you are running.  The original author’s copyright and name are first and foremost.  Next is a textbox with additional information and a summary of the monthly new features of note. Below that is a summary of the GPL License and the fact that it is provided without any warranty.  Then the licensing verbage is the item that you may need to refer to most often -- the \textit{built} date and time in case you need to know which version you are currently running.
403
404 \section{Environment Variables for Customization}%
405 \label{sec:environment_variables_customization}
406 \index{configuration!environment variables}
407
408 Environment variables are global variables in the shell which all applications can read. They are set with a command like \texttt{set VARIABLE=value} or \texttt{export VARIABLE=value}. Environment variables can be viewed with a command like \texttt{env}.   The values set can be removed with \texttt{unset VARIABLE}.
409
410 The following exported variables can be set to customize your environment. \\ The \texttt{CIN\_CONFIG} variable could be extremely useful for testing purposes or for multiple users sharing the same home directory who would like different default preference settings.
411
412 \begin{description}
413     \item[{\small CIN\_BROWSER}] name of browser to use by \textit{Shell Cmds} options
414     \item[{\small CIN\_CONFIG}] configuration data; defaults to \texttt{\$HOME/.bcast5}
415     \item[{\small CIN\_DAT}] location of data files, such as documentation, models, tip of the day
416     \item[{\small CIN\_LADSPA}] LADSPA directory path; use colons to separate multiple paths; this is convenient to define an alternate directory if you share the same executable directory among computers via NFS.
417     \item[{\small CIN\_LIB}] location of library programs, such as bdwrite
418     \item[{\small CIN\_LOCALE}] locale text domain path to use for translating text
419     \item[{\small CIN\_PLUGIN}] plugin directory path
420     \item[{\small CIN\_RENDER}] complete filename with path, that was used for \textit{select file to render} to in the current session’s last successful Render job; this is used in the \texttt{RenderMux} defined \textit{Shell Cmds} and is available for any user-defined script inside \CGG{}
421     \item[{\small CIN\_PKG}] used to set your text domain, that is the locale path pointing to the cin.mo language file
422     \item[{\small CIN\_XSYNCH}] (for Developers only) set to 1 helps debugging for windows primitives to execute immediately and not be buffered up so you can see what is happening
423 \end{description}
424
425 One example:
426
427 \begin{lstlisting}[numbers=none]
428 export CIN_BROWSER=chrome       #would override default firefox for Shell Cmds.
429 \end{lstlisting}
430
431 Another example:
432
433 \begin{lstlisting}[numbers=none]
434 export CIN_CONFIG=/tmp/.bcast5   #use a temporary setup for testing purposes.
435 \end{lstlisting}
436
437 \begin{description}
438     \item[{\small BC\_USE\_COMMERCIALS=1}] to activate the commercial database (db) methods.
439     \item[{\small BC\_TRAP\_LV2\_SEGV}] to get a dump of the failure of an LV2 plugin for help in debugging.
440     \item[{\small BC\_FONT\_SCALE=1.2}] for changing the default size of the characters to be twice as big.
441     \item[{\small BC\_ICON\_SCALE=1.1}] for changing the default size of the icons to be bigger; can change \# to any. You can increase the size of the characters in the fonts and icons on your \CGG{} system.  This will make it easier to read the characters if you have trouble seeing the default small letters, which have been auto-scaled based on the window geometry. The user-friendly font/icon scaling default is 1 but you can set it to any decimal value.  To defeat default auto scaling and get any size characters/fonts, override the setting via the previous 2 listed shell environment variables. This is very sensitive, meaning that even a small increase in the numeric value can vary the size quite dramatically.
442     \item[{\small BC\_FONT\_PATH=<colon-separated-search-path-for-fonts>}]  to add additional font sets for the \textit{Title}
443     plugin or to remove all fonts set to : \texttt{(colon)}.  An example: \texttt{export BC\_FONT\_PATH=/usr/share/fonts}.
444     \item[{\small BC\_FONT\_DEBUG=1}] debug for determining which font is causing problems.  0 for no debug.
445     \item[{\small BC\_SCALE=1.2}] for setting up scaling for your monitor where you would like the text and icons to be bigger where 1.2 is a \# chosen accordingly; in this case the text and fonts will be 1.2 times the
446 normal size of 1. Refer to the previous Appearance section, \textit{Layout Scale} for more details.
447     \item[{\small LADSPA\_PATH}] specify an alternate set of ladspa plugins or include the default with the use of a colon separated list of directories to search for LADSPA plugins. This is always used first and if it does not
448     exist, then the value for \texttt{CIN\_LADSPA} becomes \texttt{LADSPA\_PATH}.
449     \item[{\small LV2\_PATH}] specify a certain set of LV2 plugins to use.  Separate multiple paths with colons.
450     \item[{\small LANG}] \CGG{} can be localized to display menus and messages in many languages.
451 Currently there are 16 languages in addition to English, of varying quality. Some information on
452 these is in the \nameref{cha:translations} chapter.
453 Language settings are normally read from your Linux O/S \textit{locale} settings. 
454 The \CGG{} program checks environment variables to determine your settings to use as the language.
455 First it checks the value of LANGUAGE and will use that if set.
456 If that is not set, then it checks 
457 LC\_ALL and finally if that is not set either, it will use the value of LANG. You can check the current
458 settings from a window by looking at the output of the \textit{printenv} command.
459
460 To run on a language different than the one selected on your system just change 
461 the \texttt{LANG} environment variable before starting up \CGG{} like this:
462
463 \hspace{2em} \texttt{export LANG}=\textit{2 letter language code\_2 letter country code.UTF-8} 
464
465 For example, from a window type:
466
467 \hspace{2em} \texttt{export LANG=es\_ES.UTF-8} 
468
469 then startup \CGG{} and you will have translations in Spanish.  If you started \CGG{} from that same
470 window using \texttt{\{cinelerra\_path\}/bin/cin} you will see a message in that window something similar to:
471
472 \hspace{2em}  \textit{lang changed from en\_US.UTF-8 to es\_ES-UTF-8}
473
474 However, although generally LANGUAGE is not set, it is possible that another progam that was run may
475 have set it so you may have to substitute LANGUAGE for the word LANG above.
476
477 Depending on your Operating System and Desktop application, there may be other ways to accomplish a
478 language change.  For example, on Fedora with the Gnome desktop, the simplest method of switching your
479 language to German and immediately starting \CGG{} is to use:
480
481 \hspace{2em} \texttt{LANGUAGE=de \{cinelerra\_path\}/bin/cin} 
482
483
484     \item[{\small SHUTTLE\_CONFIG\_FILE}] alternate shuttle configuration file.
485 \end{description}
486