Config.cpp 68 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326
  1. /*\
  2. |*| Copyright 2015 bill-auger <https://github.com/bill-auger/av-caster/issues>
  3. |*|
  4. |*| This file is part of the AvCaster program.
  5. |*|
  6. |*| AvCaster is free software: you can redistribute it and/or modify
  7. |*| it under the terms of the GNU Lesser General Public License version 3
  8. |*| as published by the Free Software Foundation.
  9. |*|
  10. |*| AvCaster is distributed in the hope that it will be useful,
  11. |*| but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. |*| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. |*| GNU Lesser General Public License for more details.
  14. |*|
  15. |*| You should have received a copy of the GNU Lesser General Public License
  16. |*| along with AvCaster. If not, see <http://www.gnu.org/licenses/>.
  17. \*/
  18. //[Headers] You can add your own extra header files here...
  19. #include "AvCaster.h"
  20. #include "Trace/TraceConfig.h"
  21. //[/Headers]
  22. #include "Config.h"
  23. //[MiscUserDefs] You can add your own user definitions and misc code here...
  24. //[/MiscUserDefs]
  25. //==============================================================================
  26. Config::Config ()
  27. {
  28. addAndMakeVisible (screenGroup = new GroupComponent ("screenGroup",
  29. TRANS("Screen")));
  30. screenGroup->setColour (GroupComponent::outlineColourId, Colours::white);
  31. screenGroup->setColour (GroupComponent::textColourId, Colours::white);
  32. addAndMakeVisible (displayLabel = new Label ("displayLabel",
  33. TRANS("Display #:")));
  34. displayLabel->setFont (Font (15.00f, Font::plain));
  35. displayLabel->setJustificationType (Justification::centredLeft);
  36. displayLabel->setEditable (false, false, false);
  37. displayLabel->setColour (Label::textColourId, Colours::white);
  38. displayLabel->setColour (TextEditor::textColourId, Colours::black);
  39. displayLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  40. addAndMakeVisible (displaySlider = new Slider ("displaySlider"));
  41. displaySlider->setExplicitFocusOrder (1);
  42. displaySlider->setRange (0, 10, 0);
  43. displaySlider->setSliderStyle (Slider::IncDecButtons);
  44. displaySlider->setTextBoxStyle (Slider::TextBoxLeft, false, 24, 20);
  45. displaySlider->addListener (this);
  46. addAndMakeVisible (screenLabel = new Label ("screenLabel",
  47. TRANS("Screen #:")));
  48. screenLabel->setFont (Font (15.00f, Font::plain));
  49. screenLabel->setJustificationType (Justification::centredLeft);
  50. screenLabel->setEditable (false, false, false);
  51. screenLabel->setColour (Label::textColourId, Colours::white);
  52. screenLabel->setColour (TextEditor::textColourId, Colours::black);
  53. screenLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  54. addAndMakeVisible (screenSlider = new Slider ("screenSlider"));
  55. screenSlider->setExplicitFocusOrder (2);
  56. screenSlider->setRange (0, 10, 0);
  57. screenSlider->setSliderStyle (Slider::IncDecButtons);
  58. screenSlider->setTextBoxStyle (Slider::TextBoxLeft, false, 24, 20);
  59. screenSlider->addListener (this);
  60. addAndMakeVisible (screenWidthLabel = new Label ("screenWidthLabel",
  61. TRANS("Width:")));
  62. screenWidthLabel->setFont (Font (15.00f, Font::plain));
  63. screenWidthLabel->setJustificationType (Justification::centredLeft);
  64. screenWidthLabel->setEditable (false, false, false);
  65. screenWidthLabel->setColour (Label::textColourId, Colours::white);
  66. screenWidthLabel->setColour (TextEditor::textColourId, Colours::black);
  67. screenWidthLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  68. addAndMakeVisible (screenWidthText = new TextEditor ("screenWidthText"));
  69. screenWidthText->setExplicitFocusOrder (3);
  70. screenWidthText->setMultiLine (false);
  71. screenWidthText->setReturnKeyStartsNewLine (false);
  72. screenWidthText->setReadOnly (false);
  73. screenWidthText->setScrollbarsShown (false);
  74. screenWidthText->setCaretVisible (true);
  75. screenWidthText->setPopupMenuEnabled (true);
  76. screenWidthText->setText (String::empty);
  77. addAndMakeVisible (screenHeightLabel = new Label ("screenHeightLabel",
  78. TRANS("Height:")));
  79. screenHeightLabel->setFont (Font (15.00f, Font::plain));
  80. screenHeightLabel->setJustificationType (Justification::centredLeft);
  81. screenHeightLabel->setEditable (false, false, false);
  82. screenHeightLabel->setColour (Label::textColourId, Colours::white);
  83. screenHeightLabel->setColour (TextEditor::textColourId, Colours::black);
  84. screenHeightLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  85. addAndMakeVisible (screenHeightText = new TextEditor ("screenHeightText"));
  86. screenHeightText->setExplicitFocusOrder (4);
  87. screenHeightText->setMultiLine (false);
  88. screenHeightText->setReturnKeyStartsNewLine (false);
  89. screenHeightText->setReadOnly (false);
  90. screenHeightText->setScrollbarsShown (false);
  91. screenHeightText->setCaretVisible (true);
  92. screenHeightText->setPopupMenuEnabled (true);
  93. screenHeightText->setText (String::empty);
  94. addAndMakeVisible (xOffsetLabel = new Label ("xOffsetLabel",
  95. TRANS("Offset X:")));
  96. xOffsetLabel->setFont (Font (15.00f, Font::plain));
  97. xOffsetLabel->setJustificationType (Justification::centredLeft);
  98. xOffsetLabel->setEditable (false, false, false);
  99. xOffsetLabel->setColour (Label::textColourId, Colours::white);
  100. xOffsetLabel->setColour (TextEditor::textColourId, Colours::black);
  101. xOffsetLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  102. addAndMakeVisible (xOffsetText = new TextEditor ("xOffsetText"));
  103. xOffsetText->setExplicitFocusOrder (5);
  104. xOffsetText->setMultiLine (false);
  105. xOffsetText->setReturnKeyStartsNewLine (false);
  106. xOffsetText->setReadOnly (false);
  107. xOffsetText->setScrollbarsShown (true);
  108. xOffsetText->setCaretVisible (true);
  109. xOffsetText->setPopupMenuEnabled (true);
  110. xOffsetText->setText (String::empty);
  111. addAndMakeVisible (yOffsetLabel = new Label ("yOffsetLabel",
  112. TRANS("Offset Y:")));
  113. yOffsetLabel->setFont (Font (15.00f, Font::plain));
  114. yOffsetLabel->setJustificationType (Justification::centredLeft);
  115. yOffsetLabel->setEditable (false, false, false);
  116. yOffsetLabel->setColour (Label::textColourId, Colours::white);
  117. yOffsetLabel->setColour (TextEditor::textColourId, Colours::black);
  118. yOffsetLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  119. addAndMakeVisible (yOffsetText = new TextEditor ("yOffsetText"));
  120. yOffsetText->setExplicitFocusOrder (6);
  121. yOffsetText->setMultiLine (false);
  122. yOffsetText->setReturnKeyStartsNewLine (false);
  123. yOffsetText->setReadOnly (false);
  124. yOffsetText->setScrollbarsShown (true);
  125. yOffsetText->setCaretVisible (true);
  126. yOffsetText->setPopupMenuEnabled (true);
  127. yOffsetText->setText (String::empty);
  128. addAndMakeVisible (cameraGroup = new GroupComponent ("cameraGroup",
  129. TRANS("Camera")));
  130. cameraGroup->setColour (GroupComponent::outlineColourId, Colours::white);
  131. cameraGroup->setColour (GroupComponent::textColourId, Colours::white);
  132. addAndMakeVisible (cameraDevLabel = new Label ("cameraDevLabel",
  133. TRANS("Device:")));
  134. cameraDevLabel->setFont (Font (15.00f, Font::plain));
  135. cameraDevLabel->setJustificationType (Justification::centredLeft);
  136. cameraDevLabel->setEditable (false, false, false);
  137. cameraDevLabel->setColour (Label::textColourId, Colours::white);
  138. cameraDevLabel->setColour (TextEditor::textColourId, Colours::black);
  139. cameraDevLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  140. addAndMakeVisible (cameraDevCombo = new ComboBox ("cameraDevCombo"));
  141. cameraDevCombo->setExplicitFocusOrder (7);
  142. cameraDevCombo->setEditableText (false);
  143. cameraDevCombo->setJustificationType (Justification::centredLeft);
  144. cameraDevCombo->setTextWhenNothingSelected (TRANS("(no camera devices)"));
  145. cameraDevCombo->setTextWhenNoChoicesAvailable (TRANS("(no camera devices)"));
  146. cameraDevCombo->addListener (this);
  147. addAndMakeVisible (cameraResLabel = new Label ("cameraResLabel",
  148. TRANS("Resolution:")));
  149. cameraResLabel->setFont (Font (15.00f, Font::plain));
  150. cameraResLabel->setJustificationType (Justification::centredLeft);
  151. cameraResLabel->setEditable (false, false, false);
  152. cameraResLabel->setColour (Label::textColourId, Colours::white);
  153. cameraResLabel->setColour (TextEditor::textColourId, Colours::black);
  154. cameraResLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  155. addAndMakeVisible (cameraResCombo = new ComboBox ("cameraResCombo"));
  156. cameraResCombo->setExplicitFocusOrder (8);
  157. cameraResCombo->setEditableText (false);
  158. cameraResCombo->setJustificationType (Justification::centredLeft);
  159. cameraResCombo->setTextWhenNothingSelected (String::empty);
  160. cameraResCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  161. cameraResCombo->addListener (this);
  162. addAndMakeVisible (audioGroup = new GroupComponent ("audioGroup",
  163. TRANS("Audio")));
  164. audioGroup->setColour (GroupComponent::outlineColourId, Colours::white);
  165. audioGroup->setColour (GroupComponent::textColourId, Colours::white);
  166. addAndMakeVisible (audioApiLabel = new Label ("audioApiLabel",
  167. TRANS("Interface:")));
  168. audioApiLabel->setFont (Font (15.00f, Font::plain));
  169. audioApiLabel->setJustificationType (Justification::centredLeft);
  170. audioApiLabel->setEditable (false, false, false);
  171. audioApiLabel->setColour (Label::textColourId, Colours::white);
  172. audioApiLabel->setColour (TextEditor::textColourId, Colours::black);
  173. audioApiLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  174. addAndMakeVisible (audioApiCombo = new ComboBox ("audioApiCombo"));
  175. audioApiCombo->setExplicitFocusOrder (9);
  176. audioApiCombo->setEditableText (false);
  177. audioApiCombo->setJustificationType (Justification::centredLeft);
  178. audioApiCombo->setTextWhenNothingSelected (String::empty);
  179. audioApiCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  180. audioApiCombo->addListener (this);
  181. addAndMakeVisible (audioDevLabel = new Label ("audioDevLabel",
  182. TRANS("Device:")));
  183. audioDevLabel->setFont (Font (15.00f, Font::plain));
  184. audioDevLabel->setJustificationType (Justification::centredLeft);
  185. audioDevLabel->setEditable (false, false, false);
  186. audioDevLabel->setColour (Label::textColourId, Colours::white);
  187. audioDevLabel->setColour (TextEditor::textColourId, Colours::black);
  188. audioDevLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  189. addAndMakeVisible (audioDevCombo = new ComboBox ("audioDevCombo"));
  190. audioDevCombo->setExplicitFocusOrder (10);
  191. audioDevCombo->setEditableText (false);
  192. audioDevCombo->setJustificationType (Justification::centredLeft);
  193. audioDevCombo->setTextWhenNothingSelected (TRANS("(no audio devices)"));
  194. audioDevCombo->setTextWhenNoChoicesAvailable (TRANS("(no audio devices)"));
  195. audioDevCombo->addListener (this);
  196. addAndMakeVisible (audioCodecLabel = new Label ("audioCodecLabel",
  197. TRANS("Codec:")));
  198. audioCodecLabel->setFont (Font (15.00f, Font::plain));
  199. audioCodecLabel->setJustificationType (Justification::centredLeft);
  200. audioCodecLabel->setEditable (false, false, false);
  201. audioCodecLabel->setColour (Label::textColourId, Colours::white);
  202. audioCodecLabel->setColour (TextEditor::textColourId, Colours::black);
  203. audioCodecLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  204. addAndMakeVisible (audioCodecCombo = new ComboBox ("audioCodecCombo"));
  205. audioCodecCombo->setExplicitFocusOrder (11);
  206. audioCodecCombo->setEditableText (false);
  207. audioCodecCombo->setJustificationType (Justification::centredLeft);
  208. audioCodecCombo->setTextWhenNothingSelected (String::empty);
  209. audioCodecCombo->setTextWhenNoChoicesAvailable (TRANS("(no devices)"));
  210. audioCodecCombo->addListener (this);
  211. addAndMakeVisible (nChannelsLabel = new Label ("nChannelsLabel",
  212. TRANS("Channels:")));
  213. nChannelsLabel->setFont (Font (15.00f, Font::plain));
  214. nChannelsLabel->setJustificationType (Justification::centredLeft);
  215. nChannelsLabel->setEditable (false, false, false);
  216. nChannelsLabel->setColour (Label::textColourId, Colours::white);
  217. nChannelsLabel->setColour (TextEditor::textColourId, Colours::black);
  218. nChannelsLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  219. addAndMakeVisible (nChannelsSlider = new Slider ("nChannelsSlider"));
  220. nChannelsSlider->setExplicitFocusOrder (12);
  221. nChannelsSlider->setRange (0, 10, 0);
  222. nChannelsSlider->setSliderStyle (Slider::IncDecButtons);
  223. nChannelsSlider->setTextBoxStyle (Slider::TextBoxLeft, false, 24, 20);
  224. nChannelsSlider->addListener (this);
  225. addAndMakeVisible (samplerateLabel = new Label ("samplerateLabel",
  226. TRANS("Samplerate:")));
  227. samplerateLabel->setFont (Font (15.00f, Font::plain));
  228. samplerateLabel->setJustificationType (Justification::centredLeft);
  229. samplerateLabel->setEditable (false, false, false);
  230. samplerateLabel->setColour (Label::textColourId, Colours::white);
  231. samplerateLabel->setColour (TextEditor::textColourId, Colours::black);
  232. samplerateLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  233. addAndMakeVisible (samplerateCombo = new ComboBox ("samplerateCombo"));
  234. samplerateCombo->setExplicitFocusOrder (13);
  235. samplerateCombo->setEditableText (false);
  236. samplerateCombo->setJustificationType (Justification::centredLeft);
  237. samplerateCombo->setTextWhenNothingSelected (String::empty);
  238. samplerateCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  239. samplerateCombo->addListener (this);
  240. addAndMakeVisible (audioBitrateLabel = new Label ("audioBitrateLabel",
  241. TRANS("Bitrate:")));
  242. audioBitrateLabel->setFont (Font (15.00f, Font::plain));
  243. audioBitrateLabel->setJustificationType (Justification::centredLeft);
  244. audioBitrateLabel->setEditable (false, false, false);
  245. audioBitrateLabel->setColour (Label::textColourId, Colours::white);
  246. audioBitrateLabel->setColour (TextEditor::textColourId, Colours::black);
  247. audioBitrateLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  248. addAndMakeVisible (audioBitrateCombo = new ComboBox ("audioBitrateCombo"));
  249. audioBitrateCombo->setExplicitFocusOrder (14);
  250. audioBitrateCombo->setEditableText (false);
  251. audioBitrateCombo->setJustificationType (Justification::centredLeft);
  252. audioBitrateCombo->setTextWhenNothingSelected (String::empty);
  253. audioBitrateCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  254. audioBitrateCombo->addListener (this);
  255. addAndMakeVisible (textGroup = new GroupComponent ("textGroup",
  256. TRANS("Text")));
  257. textGroup->setColour (GroupComponent::outlineColourId, Colours::white);
  258. textGroup->setColour (GroupComponent::textColourId, Colours::white);
  259. addAndMakeVisible (motdLabel = new Label ("motdLabel",
  260. TRANS("Message:")));
  261. motdLabel->setFont (Font (15.00f, Font::plain));
  262. motdLabel->setJustificationType (Justification::centredLeft);
  263. motdLabel->setEditable (false, false, false);
  264. motdLabel->setColour (Label::textColourId, Colours::white);
  265. motdLabel->setColour (TextEditor::textColourId, Colours::black);
  266. motdLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  267. addAndMakeVisible (motdText = new TextEditor ("motdText"));
  268. motdText->setExplicitFocusOrder (15);
  269. motdText->setMultiLine (false);
  270. motdText->setReturnKeyStartsNewLine (false);
  271. motdText->setReadOnly (false);
  272. motdText->setScrollbarsShown (true);
  273. motdText->setCaretVisible (true);
  274. motdText->setPopupMenuEnabled (true);
  275. motdText->setText (String::empty);
  276. addAndMakeVisible (textStyleLabel = new Label ("textStyleLabel",
  277. TRANS("Style:")));
  278. textStyleLabel->setFont (Font (15.00f, Font::plain));
  279. textStyleLabel->setJustificationType (Justification::centredLeft);
  280. textStyleLabel->setEditable (false, false, false);
  281. textStyleLabel->setColour (Label::textColourId, Colours::white);
  282. textStyleLabel->setColour (TextEditor::textColourId, Colours::black);
  283. textStyleLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  284. addAndMakeVisible (textStyleCombo = new ComboBox ("textStyleCombo"));
  285. textStyleCombo->setExplicitFocusOrder (16);
  286. textStyleCombo->setEditableText (false);
  287. textStyleCombo->setJustificationType (Justification::centredLeft);
  288. textStyleCombo->setTextWhenNothingSelected (String::empty);
  289. textStyleCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  290. textStyleCombo->addListener (this);
  291. addAndMakeVisible (textPosLabel = new Label ("textPosLabel",
  292. TRANS("Position:")));
  293. textPosLabel->setFont (Font (15.00f, Font::plain));
  294. textPosLabel->setJustificationType (Justification::centredLeft);
  295. textPosLabel->setEditable (false, false, false);
  296. textPosLabel->setColour (Label::textColourId, Colours::white);
  297. textPosLabel->setColour (TextEditor::textColourId, Colours::black);
  298. textPosLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  299. addAndMakeVisible (textPosCombo = new ComboBox ("textPosCombo"));
  300. textPosCombo->setExplicitFocusOrder (17);
  301. textPosCombo->setEditableText (false);
  302. textPosCombo->setJustificationType (Justification::centredLeft);
  303. textPosCombo->setTextWhenNothingSelected (String::empty);
  304. textPosCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  305. textPosCombo->addListener (this);
  306. addAndMakeVisible (interstitialGroup = new GroupComponent ("interstitialGroup",
  307. TRANS("Interstitial")));
  308. interstitialGroup->setColour (GroupComponent::outlineColourId, Colours::white);
  309. interstitialGroup->setColour (GroupComponent::textColourId, Colours::white);
  310. addAndMakeVisible (locationLabel = new Label ("locationLabel",
  311. TRANS("Location:")));
  312. locationLabel->setFont (Font (15.00f, Font::plain));
  313. locationLabel->setJustificationType (Justification::centredLeft);
  314. locationLabel->setEditable (false, false, false);
  315. locationLabel->setColour (Label::textColourId, Colours::white);
  316. locationLabel->setColour (TextEditor::textColourId, Colours::black);
  317. locationLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  318. addAndMakeVisible (interstitialText = new TextEditor ("interstitialText"));
  319. interstitialText->setExplicitFocusOrder (18);
  320. interstitialText->setMultiLine (false);
  321. interstitialText->setReturnKeyStartsNewLine (false);
  322. interstitialText->setReadOnly (false);
  323. interstitialText->setScrollbarsShown (true);
  324. interstitialText->setCaretVisible (true);
  325. interstitialText->setPopupMenuEnabled (true);
  326. interstitialText->setText (String::empty);
  327. addAndMakeVisible (browseButton = new TextButton ("browseButton"));
  328. browseButton->setExplicitFocusOrder (19);
  329. browseButton->setButtonText (TRANS("Browse"));
  330. browseButton->addListener (this);
  331. addAndMakeVisible (outputGroup = new GroupComponent ("outputGroup",
  332. TRANS("Output")));
  333. outputGroup->setColour (GroupComponent::outlineColourId, Colours::white);
  334. outputGroup->setColour (GroupComponent::textColourId, Colours::white);
  335. addAndMakeVisible (outputStreamLabel = new Label ("outputStreamLabel",
  336. TRANS("Destination:")));
  337. outputStreamLabel->setFont (Font (15.00f, Font::plain));
  338. outputStreamLabel->setJustificationType (Justification::centredLeft);
  339. outputStreamLabel->setEditable (false, false, false);
  340. outputStreamLabel->setColour (Label::textColourId, Colours::white);
  341. outputStreamLabel->setColour (TextEditor::textColourId, Colours::black);
  342. outputStreamLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  343. addAndMakeVisible (outputSinkCombo = new ComboBox ("outputSinkCombo"));
  344. outputSinkCombo->setExplicitFocusOrder (20);
  345. outputSinkCombo->setEditableText (false);
  346. outputSinkCombo->setJustificationType (Justification::centredLeft);
  347. outputSinkCombo->setTextWhenNothingSelected (String::empty);
  348. outputSinkCombo->setTextWhenNoChoicesAvailable (TRANS("(no devices)"));
  349. outputSinkCombo->addListener (this);
  350. addAndMakeVisible (outputWidthLabel = new Label ("outputWidthLabel",
  351. TRANS("Width:")));
  352. outputWidthLabel->setFont (Font (15.00f, Font::plain));
  353. outputWidthLabel->setJustificationType (Justification::centredLeft);
  354. outputWidthLabel->setEditable (false, false, false);
  355. outputWidthLabel->setColour (Label::textColourId, Colours::white);
  356. outputWidthLabel->setColour (TextEditor::textColourId, Colours::black);
  357. outputWidthLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  358. addAndMakeVisible (outputWidthText = new TextEditor ("outputWidthText"));
  359. outputWidthText->setExplicitFocusOrder (21);
  360. outputWidthText->setMultiLine (false);
  361. outputWidthText->setReturnKeyStartsNewLine (false);
  362. outputWidthText->setReadOnly (false);
  363. outputWidthText->setScrollbarsShown (false);
  364. outputWidthText->setCaretVisible (false);
  365. outputWidthText->setPopupMenuEnabled (true);
  366. outputWidthText->setText (String::empty);
  367. addAndMakeVisible (outputHeightLabel = new Label ("outputHeightLabel",
  368. TRANS("Height:")));
  369. outputHeightLabel->setFont (Font (15.00f, Font::plain));
  370. outputHeightLabel->setJustificationType (Justification::centredLeft);
  371. outputHeightLabel->setEditable (false, false, false);
  372. outputHeightLabel->setColour (Label::textColourId, Colours::white);
  373. outputHeightLabel->setColour (TextEditor::textColourId, Colours::black);
  374. outputHeightLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  375. addAndMakeVisible (outputHeightText = new TextEditor ("outputHeightText"));
  376. outputHeightText->setExplicitFocusOrder (22);
  377. outputHeightText->setMultiLine (false);
  378. outputHeightText->setReturnKeyStartsNewLine (false);
  379. outputHeightText->setReadOnly (false);
  380. outputHeightText->setScrollbarsShown (false);
  381. outputHeightText->setCaretVisible (false);
  382. outputHeightText->setPopupMenuEnabled (true);
  383. outputHeightText->setText (String::empty);
  384. addAndMakeVisible (framerateLabel = new Label ("framerateLabel",
  385. TRANS("FPS:")));
  386. framerateLabel->setFont (Font (15.00f, Font::plain));
  387. framerateLabel->setJustificationType (Justification::centredLeft);
  388. framerateLabel->setEditable (false, false, false);
  389. framerateLabel->setColour (Label::textColourId, Colours::white);
  390. framerateLabel->setColour (TextEditor::textColourId, Colours::black);
  391. framerateLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  392. addAndMakeVisible (framerateCombo = new ComboBox ("framerateCombo"));
  393. framerateCombo->setExplicitFocusOrder (23);
  394. framerateCombo->setEditableText (false);
  395. framerateCombo->setJustificationType (Justification::centredLeft);
  396. framerateCombo->setTextWhenNothingSelected (String::empty);
  397. framerateCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  398. framerateCombo->addListener (this);
  399. addAndMakeVisible (bitrateLabel = new Label ("bitrateLabel",
  400. TRANS("Bitrate:")));
  401. bitrateLabel->setFont (Font (15.00f, Font::plain));
  402. bitrateLabel->setJustificationType (Justification::centredLeft);
  403. bitrateLabel->setEditable (false, false, false);
  404. bitrateLabel->setColour (Label::textColourId, Colours::white);
  405. bitrateLabel->setColour (TextEditor::textColourId, Colours::black);
  406. bitrateLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  407. addAndMakeVisible (videoBitrateCombo = new ComboBox ("videoBitrateCombo"));
  408. videoBitrateCombo->setExplicitFocusOrder (24);
  409. videoBitrateCombo->setEditableText (false);
  410. videoBitrateCombo->setJustificationType (Justification::centredLeft);
  411. videoBitrateCombo->setTextWhenNothingSelected (String::empty);
  412. videoBitrateCombo->setTextWhenNoChoicesAvailable (TRANS("(no choices)"));
  413. videoBitrateCombo->addListener (this);
  414. addAndMakeVisible (outputDestLabel = new Label ("outputDestLabel",
  415. TRANS("Location:")));
  416. outputDestLabel->setFont (Font (15.00f, Font::plain));
  417. outputDestLabel->setJustificationType (Justification::centredLeft);
  418. outputDestLabel->setEditable (false, false, false);
  419. outputDestLabel->setColour (Label::textColourId, Colours::white);
  420. outputDestLabel->setColour (TextEditor::textColourId, Colours::black);
  421. outputDestLabel->setColour (TextEditor::backgroundColourId, Colour (0x00000000));
  422. addAndMakeVisible (outputDestText = new TextEditor ("outputDestText"));
  423. outputDestText->setExplicitFocusOrder (25);
  424. outputDestText->setMultiLine (false);
  425. outputDestText->setReturnKeyStartsNewLine (false);
  426. outputDestText->setReadOnly (false);
  427. outputDestText->setScrollbarsShown (true);
  428. outputDestText->setCaretVisible (true);
  429. outputDestText->setPopupMenuEnabled (true);
  430. outputDestText->setText (String::empty);
  431. //[UserPreSize]
  432. //[/UserPreSize]
  433. setSize (1, 1);
  434. //[Constructor] You can add your own custom stuff here..
  435. configureSlider(this->displaySlider ) ;
  436. configureSlider(this->screenSlider ) ;
  437. configureSlider(this->nChannelsSlider) ;
  438. configureTextEditor(this->screenWidthText , GUI::MAX_RES_N_CHARS , APP::DIGITS ) ;
  439. configureTextEditor(this->screenHeightText , GUI::MAX_RES_N_CHARS , APP::DIGITS ) ;
  440. configureTextEditor(this->xOffsetText , GUI::MAX_RES_N_CHARS , APP::DIGITS ) ;
  441. configureTextEditor(this->yOffsetText , GUI::MAX_RES_N_CHARS , APP::DIGITS ) ;
  442. configureTextEditor(this->motdText , GUI::MAX_MOTD_LEN , "" ) ;
  443. configureTextEditor(this->interstitialText , GUI::MAX_FILENAME_LEN , APP::VALID_ID_CHARS ) ;
  444. configureTextEditor(this->outputWidthText , GUI::MAX_RES_N_CHARS , APP::DIGITS ) ;
  445. configureTextEditor(this->outputHeightText , GUI::MAX_RES_N_CHARS , APP::DIGITS ) ;
  446. configureTextEditor(this->outputDestText , GUI::MAX_FILENAME_LEN , APP::VALID_URI_CHARS) ;
  447. configureCombobox(this->cameraDevCombo ) ;
  448. configureCombobox(this->cameraResCombo ) ;
  449. configureCombobox(this->audioApiCombo ) ;
  450. configureCombobox(this->audioDevCombo ) ;
  451. configureCombobox(this->audioCodecCombo ) ;
  452. configureCombobox(this->samplerateCombo ) ;
  453. configureCombobox(this->audioBitrateCombo) ;
  454. configureCombobox(this->textStyleCombo ) ;
  455. configureCombobox(this->textPosCombo ) ;
  456. configureCombobox(this->outputSinkCombo ) ;
  457. configureCombobox(this->framerateCombo ) ;
  458. configureCombobox(this->videoBitrateCombo) ;
  459. // TODO: validations here or AvCasterStore->sanitizeConfig()
  460. //this->displaySlider->setRange(0 , GUI::MAX_DISPLAY_N , 1) ;
  461. //[/Constructor]
  462. }
  463. Config::~Config()
  464. {
  465. //[Destructor_pre]. You can add your own custom destruction code here..
  466. //[/Destructor_pre]
  467. screenGroup = nullptr;
  468. displayLabel = nullptr;
  469. displaySlider = nullptr;
  470. screenLabel = nullptr;
  471. screenSlider = nullptr;
  472. screenWidthLabel = nullptr;
  473. screenWidthText = nullptr;
  474. screenHeightLabel = nullptr;
  475. screenHeightText = nullptr;
  476. xOffsetLabel = nullptr;
  477. xOffsetText = nullptr;
  478. yOffsetLabel = nullptr;
  479. yOffsetText = nullptr;
  480. cameraGroup = nullptr;
  481. cameraDevLabel = nullptr;
  482. cameraDevCombo = nullptr;
  483. cameraResLabel = nullptr;
  484. cameraResCombo = nullptr;
  485. audioGroup = nullptr;
  486. audioApiLabel = nullptr;
  487. audioApiCombo = nullptr;
  488. audioDevLabel = nullptr;
  489. audioDevCombo = nullptr;
  490. audioCodecLabel = nullptr;
  491. audioCodecCombo = nullptr;
  492. nChannelsLabel = nullptr;
  493. nChannelsSlider = nullptr;
  494. samplerateLabel = nullptr;
  495. samplerateCombo = nullptr;
  496. audioBitrateLabel = nullptr;
  497. audioBitrateCombo = nullptr;
  498. textGroup = nullptr;
  499. motdLabel = nullptr;
  500. motdText = nullptr;
  501. textStyleLabel = nullptr;
  502. textStyleCombo = nullptr;
  503. textPosLabel = nullptr;
  504. textPosCombo = nullptr;
  505. interstitialGroup = nullptr;
  506. locationLabel = nullptr;
  507. interstitialText = nullptr;
  508. browseButton = nullptr;
  509. outputGroup = nullptr;
  510. outputStreamLabel = nullptr;
  511. outputSinkCombo = nullptr;
  512. outputWidthLabel = nullptr;
  513. outputWidthText = nullptr;
  514. outputHeightLabel = nullptr;
  515. outputHeightText = nullptr;
  516. framerateLabel = nullptr;
  517. framerateCombo = nullptr;
  518. bitrateLabel = nullptr;
  519. videoBitrateCombo = nullptr;
  520. outputDestLabel = nullptr;
  521. outputDestText = nullptr;
  522. //[Destructor]. You can add your own custom destruction code here..
  523. //[/Destructor]
  524. }
  525. //==============================================================================
  526. void Config::paint (Graphics& g)
  527. {
  528. //[UserPrePaint] Add your own custom painting code here..
  529. //[/UserPrePaint]
  530. g.setColour (Colour (0xff303030));
  531. g.fillRoundedRectangle (20.0f, 18.0f, static_cast<float> (getWidth() - 40), 86.0f, 4.000f);
  532. g.setColour (Colour (0xff303030));
  533. g.fillRoundedRectangle (20.0f, 126.0f, static_cast<float> (getWidth() - 40), 52.0f, 4.000f);
  534. g.setColour (Colour (0xff303030));
  535. g.fillRoundedRectangle (20.0f, 198.0f, static_cast<float> (getWidth() - 40), 88.0f, 4.000f);
  536. g.setColour (Colour (0xff303030));
  537. g.fillRoundedRectangle (20.0f, 304.0f, static_cast<float> (getWidth() - 40), 52.0f, 4.000f);
  538. g.setColour (Colour (0xff303030));
  539. g.fillRoundedRectangle (20.0f, 376.0f, static_cast<float> (getWidth() - 40), 54.0f, 4.000f);
  540. g.setColour (Colour (0xff303030));
  541. g.fillRoundedRectangle (20.0f, 450.0f, static_cast<float> (getWidth() - 40), 86.0f, 4.000f);
  542. //[UserPaint] Add your own custom painting code here..
  543. //[/UserPaint]
  544. }
  545. void Config::resized()
  546. {
  547. //[UserPreResize] Add your own custom resize code here..
  548. //[/UserPreResize]
  549. screenGroup->setBounds (16, 8, getWidth() - 32, 100);
  550. displayLabel->setBounds (32, 32, 80, 24);
  551. displaySlider->setBounds (120, 32, 64, 24);
  552. screenLabel->setBounds (32, 64, 80, 24);
  553. screenSlider->setBounds (120, 64, 64, 24);
  554. screenWidthLabel->setBounds (200, 32, 64, 24);
  555. screenWidthText->setBounds (264, 32, 48, 24);
  556. screenHeightLabel->setBounds (200, 64, 64, 24);
  557. screenHeightText->setBounds (264, 64, 48, 24);
  558. xOffsetLabel->setBounds (326, 32, 64, 24);
  559. xOffsetText->setBounds (390, 32, 48, 24);
  560. yOffsetLabel->setBounds (326, 64, 64, 24);
  561. yOffsetText->setBounds (390, 64, 48, 24);
  562. cameraGroup->setBounds (16, 116, getWidth() - 32, 64);
  563. cameraDevLabel->setBounds (32, 140, 80, 24);
  564. cameraDevCombo->setBounds (120, 140, 200, 24);
  565. cameraResLabel->setBounds (332, 140, 80, 24);
  566. cameraResCombo->setBounds (420, 140, 200, 24);
  567. audioGroup->setBounds (16, 188, getWidth() - 32, 100);
  568. audioApiLabel->setBounds (32, 212, 64, 24);
  569. audioApiCombo->setBounds (120, 212, 200, 24);
  570. audioDevLabel->setBounds (332, 212, 80, 24);
  571. audioDevCombo->setBounds (420, 212, 200, 24);
  572. audioCodecLabel->setBounds (33, 248, 80, 24);
  573. audioCodecCombo->setBounds (121, 248, 96, 24);
  574. nChannelsLabel->setBounds (232, 248, 80, 24);
  575. nChannelsSlider->setBounds (320, 248, 64, 24);
  576. samplerateLabel->setBounds (395, 248, 76, 24);
  577. samplerateCombo->setBounds (478, 248, 80, 24);
  578. audioBitrateLabel->setBounds (574, 248, 64, 24);
  579. audioBitrateCombo->setBounds (640, 248, 80, 24);
  580. textGroup->setBounds (16, 296, getWidth() - 32, 64);
  581. motdLabel->setBounds (32, 320, 80, 24);
  582. motdText->setBounds (120, 320, 284, 24);
  583. textStyleLabel->setBounds (420, 320, 52, 24);
  584. textStyleCombo->setBounds (480, 320, 80, 24);
  585. textPosLabel->setBounds (568, 320, 64, 24);
  586. textPosCombo->setBounds (640, 320, 80, 24);
  587. interstitialGroup->setBounds (18, 368, getWidth() - 32, 64);
  588. locationLabel->setBounds (34, 392, 80, 24);
  589. interstitialText->setBounds (122, 392, 486, 24);
  590. browseButton->setBounds (640, 392, 80, 24);
  591. outputGroup->setBounds (16, 440, getWidth() - 32, 100);
  592. outputStreamLabel->setBounds (32, 464, 80, 24);
  593. outputSinkCombo->setBounds (120, 464, 64, 24);
  594. outputWidthLabel->setBounds (204, 464, 64, 24);
  595. outputWidthText->setBounds (268, 464, 48, 24);
  596. outputHeightLabel->setBounds (332, 464, 64, 24);
  597. outputHeightText->setBounds (396, 464, 48, 24);
  598. framerateLabel->setBounds (460, 464, 40, 24);
  599. framerateCombo->setBounds (506, 464, 48, 24);
  600. bitrateLabel->setBounds (572, 464, 64, 24);
  601. videoBitrateCombo->setBounds (640, 464, 80, 24);
  602. outputDestLabel->setBounds (32, 500, 80, 24);
  603. outputDestText->setBounds (120, 500, 600, 24);
  604. //[UserResized] Add your own custom resize handling here..
  605. //[/UserResized]
  606. }
  607. void Config::sliderValueChanged (Slider* sliderThatWasMoved)
  608. {
  609. //[UsersliderValueChanged_Pre]
  610. Identifier key ;
  611. var value = var((int)sliderThatWasMoved->getValue()) ;
  612. //[/UsersliderValueChanged_Pre]
  613. if (sliderThatWasMoved == displaySlider)
  614. {
  615. //[UserSliderCode_displaySlider] -- add your slider handling code here..
  616. key = CONFIG::DISPLAY_N_ID ;
  617. //[/UserSliderCode_displaySlider]
  618. }
  619. else if (sliderThatWasMoved == screenSlider)
  620. {
  621. //[UserSliderCode_screenSlider] -- add your slider handling code here..
  622. key = CONFIG::SCREEN_N_ID ;
  623. //[/UserSliderCode_screenSlider]
  624. }
  625. else if (sliderThatWasMoved == nChannelsSlider)
  626. {
  627. //[UserSliderCode_nChannelsSlider] -- add your slider handling code here..
  628. key = CONFIG::N_CHANNELS_ID ;
  629. //[/UserSliderCode_nChannelsSlider]
  630. }
  631. //[UsersliderValueChanged_Post]
  632. AvCaster::SetConfig(key , value) ;
  633. //[/UsersliderValueChanged_Post]
  634. }
  635. void Config::comboBoxChanged (ComboBox* comboBoxThatHasChanged)
  636. {
  637. //[UsercomboBoxChanged_Pre]
  638. int option_n = comboBoxThatHasChanged->getSelectedItemIndex() ;
  639. int default_idx ;
  640. Identifier key ;
  641. var value ;
  642. //[/UsercomboBoxChanged_Pre]
  643. if (comboBoxThatHasChanged == cameraDevCombo)
  644. {
  645. //[UserComboBoxCode_cameraDevCombo] -- add your combo box handling code here..
  646. key = CONFIG::CAMERA_DEVICE_ID ;
  647. default_idx = CONFIG::DEFAULT_CAMERA_DEVICE_IDX ;
  648. //[/UserComboBoxCode_cameraDevCombo]
  649. }
  650. else if (comboBoxThatHasChanged == cameraResCombo)
  651. {
  652. //[UserComboBoxCode_cameraResCombo] -- add your combo box handling code here..
  653. key = CONFIG::CAMERA_RES_ID ;
  654. default_idx = CONFIG::DEFAULT_CAMERA_RES_IDX ;
  655. //[/UserComboBoxCode_cameraResCombo]
  656. }
  657. else if (comboBoxThatHasChanged == audioApiCombo)
  658. {
  659. //[UserComboBoxCode_audioApiCombo] -- add your combo box handling code here..
  660. key = CONFIG::AUDIO_API_ID ;
  661. default_idx = CONFIG::DEFAULT_AUDIO_API_IDX ;
  662. //[/UserComboBoxCode_audioApiCombo]
  663. }
  664. else if (comboBoxThatHasChanged == audioDevCombo)
  665. {
  666. //[UserComboBoxCode_audioDevCombo] -- add your combo box handling code here..
  667. key = CONFIG::AUDIO_DEVICE_ID ;
  668. default_idx = CONFIG::DEFAULT_AUDIO_DEVICE_IDX ;
  669. //[/UserComboBoxCode_audioDevCombo]
  670. }
  671. else if (comboBoxThatHasChanged == audioCodecCombo)
  672. {
  673. //[UserComboBoxCode_audioCodecCombo] -- add your combo box handling code here..
  674. key = CONFIG::AUDIO_CODEC_ID ;
  675. default_idx = CONFIG::DEFAULT_AUDIO_CODEC_IDX ;
  676. //[/UserComboBoxCode_audioCodecCombo]
  677. }
  678. else if (comboBoxThatHasChanged == samplerateCombo)
  679. {
  680. //[UserComboBoxCode_samplerateCombo] -- add your combo box handling code here..
  681. key = CONFIG::SAMPLERATE_ID ;
  682. default_idx = CONFIG::DEFAULT_SAMPLERATE_IDX ;
  683. //[/UserComboBoxCode_samplerateCombo]
  684. }
  685. else if (comboBoxThatHasChanged == audioBitrateCombo)
  686. {
  687. //[UserComboBoxCode_audioBitrateCombo] -- add your combo box handling code here..
  688. key = CONFIG::AUDIO_BITRATE_ID ;
  689. default_idx = CONFIG::DEFAULT_AUDIO_BITRATE_IDX ;
  690. //[/UserComboBoxCode_audioBitrateCombo]
  691. }
  692. else if (comboBoxThatHasChanged == textStyleCombo)
  693. {
  694. //[UserComboBoxCode_textStyleCombo] -- add your combo box handling code here..
  695. key = CONFIG::TEXT_STYLE_ID ;
  696. default_idx = CONFIG::DEFAULT_TEXT_STYLE_IDX ;
  697. //[/UserComboBoxCode_textStyleCombo]
  698. }
  699. else if (comboBoxThatHasChanged == textPosCombo)
  700. {
  701. //[UserComboBoxCode_textPosCombo] -- add your combo box handling code here..
  702. key = CONFIG::TEXT_POSITION_ID ;
  703. default_idx = CONFIG::DEFAULT_TEXT_POSITION_IDX ;
  704. //[/UserComboBoxCode_textPosCombo]
  705. }
  706. else if (comboBoxThatHasChanged == outputSinkCombo)
  707. {
  708. //[UserComboBoxCode_outputSinkCombo] -- add your combo box handling code here..
  709. key = CONFIG::OUTPUT_SINK_ID ;
  710. default_idx = CONFIG::DEFAULT_OUTPUT_SINK_IDX ;
  711. //[/UserComboBoxCode_outputSinkCombo]
  712. }
  713. else if (comboBoxThatHasChanged == framerateCombo)
  714. {
  715. //[UserComboBoxCode_framerateCombo] -- add your combo box handling code here..
  716. key = CONFIG::FRAMERATE_ID ;
  717. default_idx = CONFIG::DEFAULT_FRAMERATE_IDX ;
  718. //[/UserComboBoxCode_framerateCombo]
  719. }
  720. else if (comboBoxThatHasChanged == videoBitrateCombo)
  721. {
  722. //[UserComboBoxCode_videoBitrateCombo] -- add your combo box handling code here..
  723. key = CONFIG::VIDEO_BITRATE_ID ;
  724. default_idx = CONFIG::DEFAULT_VIDEO_BITRATE_IDX ;
  725. //[/UserComboBoxCode_videoBitrateCombo]
  726. }
  727. //[UsercomboBoxChanged_Post]
  728. else return ;
  729. value = var((~option_n) ? option_n : default_idx) ;
  730. comboBoxThatHasChanged->setSelectedItemIndex(int(value) , juce::dontSendNotification) ;
  731. AvCaster::SetConfig(key , value) ;
  732. //[/UsercomboBoxChanged_Post]
  733. }
  734. void Config::buttonClicked (Button* buttonThatWasClicked)
  735. {
  736. //[UserbuttonClicked_Pre]
  737. Identifier key ;
  738. var value ;
  739. //[/UserbuttonClicked_Pre]
  740. if (buttonThatWasClicked == browseButton)
  741. {
  742. //[UserButtonCode_browseButton] -- add your button handler code here..
  743. FileChooser chooser(GUI::IMAGE_CHOOSER_TEXT , APP::HOME_DIR , APP::IMG_FILE_EXTS) ;
  744. if (!chooser.browseForFileToOpen()) return ;
  745. key = CONFIG::IMAGE_ID ;
  746. value = var(chooser.getResult().getFullPathName()) ;
  747. //[/UserButtonCode_browseButton]
  748. }
  749. //[UserbuttonClicked_Post]
  750. AvCaster::SetConfig(key , value) ;
  751. //[/UserbuttonClicked_Post]
  752. }
  753. //[MiscUserCode] You can add your own definitions of your custom methods or any other code here...
  754. void Config::broughtToFront() { loadConfig() ; }
  755. void Config::textEditorFocusLost(TextEditor& a_text_editor)
  756. {
  757. TextEditor* ed = &a_text_editor ;
  758. var str_var = var(ed->getText()) ;
  759. var int_var = var(ed->getText().getIntValue()) ;
  760. Identifier key ;
  761. var value ;
  762. if (ed == this->screenWidthText ) { key = CONFIG::SCREENCAP_W_ID ; value = int_var ; }
  763. else if (ed == this->screenHeightText) { key = CONFIG::SCREENCAP_H_ID ; value = int_var ; }
  764. else if (ed == this->xOffsetText ) { key = CONFIG::OFFSET_X_ID ; value = int_var ; }
  765. else if (ed == this->yOffsetText ) { key = CONFIG::OFFSET_Y_ID ; value = int_var ; }
  766. else if (ed == this->motdText ) { key = CONFIG::MOTD_TEXT_ID ; value = str_var ; }
  767. else if (ed == this->interstitialText) { key = CONFIG::IMAGE_ID ; value = str_var ; }
  768. else if (ed == this->outputWidthText ) { key = CONFIG::OUTPUT_W_ID ; value = int_var ; }
  769. else if (ed == this->outputHeightText) { key = CONFIG::OUTPUT_H_ID ; value = int_var ; }
  770. else if (ed == this->outputDestText ) { key = CONFIG::OUTPUT_DEST_ID ; value = str_var ; }
  771. else return ;
  772. AvCaster::SetConfig(key , value) ;
  773. }
  774. void Config::configureSlider(Slider* a_slider)
  775. {
  776. a_slider->setColour(Slider::textBoxBackgroundColourId , GUI::TEXT_BG_COLOR ) ;
  777. a_slider->setColour(Slider::textBoxTextColourId , GUI::TEXT_NORMAL_COLOR ) ;
  778. a_slider->setColour(CaretComponent::caretColourId , GUI::TEXT_CARET_COLOR ) ;
  779. a_slider->setColour(TextEditor::highlightColourId , GUI::TEXT_HILITEBG_COLOR) ;
  780. a_slider->setColour(TextEditor::highlightedTextColourId , GUI::TEXT_HILITE_COLOR ) ;
  781. }
  782. void Config::configureTextEditor(TextEditor* a_text_editor , int max_n_chars ,
  783. const String allowed_chars )
  784. {
  785. a_text_editor->setSelectAllWhenFocused(true) ;
  786. a_text_editor->setInputRestrictions(max_n_chars , allowed_chars) ;
  787. a_text_editor->setColour(TextEditor::backgroundColourId , GUI::TEXT_BG_COLOR ) ;
  788. a_text_editor->setColour(TextEditor::textColourId , GUI::TEXT_NORMAL_COLOR ) ;
  789. a_text_editor->setColour(CaretComponent::caretColourId , GUI::TEXT_CARET_COLOR ) ;
  790. a_text_editor->setColour(TextEditor::highlightColourId , GUI::TEXT_HILITEBG_COLOR) ;
  791. a_text_editor->setColour(TextEditor::highlightedTextColourId , GUI::TEXT_HILITE_COLOR ) ;
  792. a_text_editor->addListener(this) ;
  793. }
  794. void Config::configureCombobox(ComboBox* a_combobox)
  795. {
  796. a_combobox->setColour(ComboBox::textColourId , GUI::TEXT_NORMAL_COLOR) ;
  797. a_combobox->setColour(ComboBox::backgroundColourId , GUI::TEXT_BG_COLOR ) ;
  798. }
  799. void Config::loadConfig()
  800. {
  801. ValueTree config_store = AvCaster::GetConfigStore() ;
  802. StringArray camera_devices = AvCaster::GetCameraNames() ;
  803. StringArray camera_resolutions = AvCaster::GetCameraResolutions() ;
  804. StringArray audio_devices = AvCaster::GetAudioNames() ;
  805. DEBUG_TRACE_CONFIG_LOAD_CONFIG
  806. double display_n = double(config_store[CONFIG::DISPLAY_N_ID ]) ;
  807. double screen_n = double(config_store[CONFIG::SCREEN_N_ID ]) ;
  808. String screencap_w = STRING(config_store[CONFIG::SCREENCAP_W_ID ]) ;
  809. String screencap_h = STRING(config_store[CONFIG::SCREENCAP_H_ID ]) ;
  810. String offset_x = STRING(config_store[CONFIG::OFFSET_X_ID ]) ;
  811. String offset_y = STRING(config_store[CONFIG::OFFSET_Y_ID ]) ;
  812. int camera_dev_idx = int (config_store[CONFIG::CAMERA_DEVICE_ID]) ;
  813. int camera_res_idx = int (config_store[CONFIG::CAMERA_RES_ID ]) ;
  814. int audio_api_idx = int (config_store[CONFIG::AUDIO_API_ID ]) ;
  815. int audio_dev_idx = int (config_store[CONFIG::AUDIO_DEVICE_ID ]) ;
  816. int audio_codec_idx = int (config_store[CONFIG::AUDIO_CODEC_ID ]) ;
  817. double n_channels = double(config_store[CONFIG::N_CHANNELS_ID ]) ;
  818. int samplerate_idx = int (config_store[CONFIG::SAMPLERATE_ID ]) ;
  819. int audio_bitrate_idx = int (config_store[CONFIG::AUDIO_BITRATE_ID]) ;
  820. int text_style_idx = int (config_store[CONFIG::TEXT_STYLE_ID ]) ;
  821. int text_pos_idx = int (config_store[CONFIG::TEXT_POSITION_ID]) ;
  822. String motd_text = STRING(config_store[CONFIG::MOTD_TEXT_ID ]) ;
  823. String interstitial_text = STRING(config_store[CONFIG::IMAGE_ID ]) ;
  824. int output_idx = int (config_store[CONFIG::OUTPUT_SINK_ID ]) ;
  825. String output_w_text = STRING(config_store[CONFIG::OUTPUT_W_ID ]) ;
  826. String output_h_text = STRING(config_store[CONFIG::OUTPUT_H_ID ]) ;
  827. int framerate_idx = int (config_store[CONFIG::FRAMERATE_ID ]) ;
  828. int video_bitrate_idx = int (config_store[CONFIG::VIDEO_BITRATE_ID]) ;
  829. String output_dest_text = STRING(config_store[CONFIG::OUTPUT_DEST_ID ]) ;
  830. bool is_lctv_preset = AvCaster::GetPresetIdx() == CONFIG::LCTV_PRESET_IDX ;
  831. String output_label_text = (is_lctv_preset ) ? GUI::DEST_LCTV_TEXT :
  832. (output_idx == CONFIG::FILE_OUTPUT_IDX) ? GUI::DEST_FILE_TEXT :
  833. (output_idx == CONFIG::RTMP_OUTPUT_IDX) ? GUI::DEST_RTMP_TEXT :
  834. "ERR" ;
  835. this->displaySlider ->setValue (display_n ) ;
  836. this->screenSlider ->setValue (screen_n ) ;
  837. this->nChannelsSlider ->setValue (n_channels) ;
  838. this->screenWidthText ->setText (screencap_w ) ;
  839. this->screenHeightText ->setText (screencap_h ) ;
  840. this->xOffsetText ->setText (offset_x ) ;
  841. this->yOffsetText ->setText (offset_y ) ;
  842. this->motdText ->setText (motd_text ) ;
  843. this->interstitialText ->setText (interstitial_text) ;
  844. this->outputWidthText ->setText (output_w_text ) ;
  845. this->outputHeightText ->setText (output_h_text ) ;
  846. this->outputDestText ->setText (output_dest_text ) ;
  847. this->outputDestLabel ->setText (output_label_text , juce::dontSendNotification) ;
  848. this->cameraDevCombo ->clear (juce::dontSendNotification) ;
  849. this->cameraResCombo ->clear (juce::dontSendNotification) ;
  850. this->audioDevCombo ->clear (juce::dontSendNotification) ;
  851. this->audioApiCombo ->clear (juce::dontSendNotification) ;
  852. this->audioCodecCombo ->clear (juce::dontSendNotification) ;
  853. this->samplerateCombo ->clear (juce::dontSendNotification) ;
  854. this->audioBitrateCombo->clear (juce::dontSendNotification) ;
  855. this->textStyleCombo ->clear (juce::dontSendNotification) ;
  856. this->textPosCombo ->clear (juce::dontSendNotification) ;
  857. this->outputSinkCombo ->clear (juce::dontSendNotification) ;
  858. this->framerateCombo ->clear (juce::dontSendNotification) ;
  859. this->videoBitrateCombo->clear (juce::dontSendNotification) ;
  860. this->cameraDevCombo ->addItemList (camera_devices , 1) ;
  861. this->cameraResCombo ->addItemList (camera_resolutions , 1) ;
  862. this->audioApiCombo ->addItemList (CONFIG::AUDIO_APIS , 1) ;
  863. this->audioDevCombo ->addItemList (audio_devices , 1) ;
  864. this->audioCodecCombo ->addItemList (CONFIG::AUDIO_CODECS , 1) ;
  865. this->samplerateCombo ->addItemList (CONFIG::AUDIO_SAMPLERATES , 1) ;
  866. this->audioBitrateCombo->addItemList (CONFIG::AUDIO_BITRATES , 1) ;
  867. this->textStyleCombo ->addItemList (CONFIG::TEXT_STYLES , 1) ;
  868. this->textPosCombo ->addItemList (CONFIG::TEXT_POSITIONS , 1) ;
  869. this->outputSinkCombo ->addItemList (CONFIG::OUTPUT_SINKS , 1) ;
  870. this->framerateCombo ->addItemList (CONFIG::FRAMERATES , 1) ;
  871. this->videoBitrateCombo->addItemList (CONFIG::VIDEO_BITRATES , 1) ;
  872. this->cameraDevCombo ->setSelectedItemIndex(camera_dev_idx , juce::dontSendNotification) ;
  873. this->cameraResCombo ->setSelectedItemIndex(camera_res_idx , juce::dontSendNotification) ;
  874. this->audioApiCombo ->setSelectedItemIndex(audio_api_idx , juce::dontSendNotification) ;
  875. this->audioDevCombo ->setSelectedItemIndex(audio_dev_idx , juce::dontSendNotification) ;
  876. this->audioCodecCombo ->setSelectedItemIndex(audio_codec_idx , juce::dontSendNotification) ;
  877. this->samplerateCombo ->setSelectedItemIndex(samplerate_idx , juce::dontSendNotification) ;
  878. this->audioBitrateCombo->setSelectedItemIndex(audio_bitrate_idx , juce::dontSendNotification) ;
  879. this->textStyleCombo ->setSelectedItemIndex(text_style_idx , juce::dontSendNotification) ;
  880. this->textPosCombo ->setSelectedItemIndex(text_pos_idx , juce::dontSendNotification) ;
  881. this->outputSinkCombo ->setSelectedItemIndex(output_idx , juce::dontSendNotification) ;
  882. this->framerateCombo ->setSelectedItemIndex(framerate_idx , juce::dontSendNotification) ;
  883. this->videoBitrateCombo->setSelectedItemIndex(video_bitrate_idx , juce::dontSendNotification) ;
  884. enableComponents() ;
  885. }
  886. void Config::enableComponents()
  887. {
  888. bool is_static_preset = AvCaster::IsStaticPreset() ;
  889. this->audioCodecCombo->setEnabled(!is_static_preset) ; // TODO: videoCodecCombo
  890. this->outputSinkCombo->setEnabled(!is_static_preset) ; // TODO: outputMuxerCombo
  891. #ifdef DISABLE_GUI_CONTROLS_NYI
  892. this->displaySlider ->setEnabled(false) ;
  893. this->screenSlider ->setEnabled(false) ;
  894. this->xOffsetText ->setEnabled(false) ;
  895. this->yOffsetText ->setEnabled(false) ;
  896. this->cameraResCombo ->setEnabled(false) ;
  897. this->audioDevCombo ->setEnabled(false) ;
  898. this->audioCodecCombo ->setEnabled(false) ;
  899. this->motdText ->setEnabled(false) ;
  900. this->textStyleCombo ->setEnabled(false) ;
  901. this->textPosCombo ->setEnabled(false) ;
  902. this->interstitialText->setEnabled(false) ;
  903. this->browseButton ->setEnabled(false) ;
  904. #endif // DISABLE_GUI_CONTROLS_NYI
  905. }
  906. //[/MiscUserCode]
  907. //==============================================================================
  908. #if 0
  909. /* -- Introjucer information section --
  910. This is where the Introjucer stores the metadata that describe this GUI layout, so
  911. make changes in here at your peril!
  912. BEGIN_JUCER_METADATA
  913. <JUCER_COMPONENT documentType="Component" className="Config" componentName=""
  914. parentClasses="public Component, public TextEditor::Listener"
  915. constructorParams="" variableInitialisers="" snapPixels="8" snapActive="1"
  916. snapShown="1" overlayOpacity="0.330" fixedSize="0" initialWidth="1"
  917. initialHeight="1">
  918. <BACKGROUND backgroundColour="0">
  919. <ROUNDRECT pos="20 18 40M 86" cornerSize="4" fill="solid: ff303030" hasStroke="0"/>
  920. <ROUNDRECT pos="20 126 40M 52" cornerSize="4" fill="solid: ff303030" hasStroke="0"/>
  921. <ROUNDRECT pos="20 198 40M 88" cornerSize="4" fill="solid: ff303030" hasStroke="0"/>
  922. <ROUNDRECT pos="20 304 40M 52" cornerSize="4" fill="solid: ff303030" hasStroke="0"/>
  923. <ROUNDRECT pos="20 376 40M 54" cornerSize="4" fill="solid: ff303030" hasStroke="0"/>
  924. <ROUNDRECT pos="20 450 40M 86" cornerSize="4" fill="solid: ff303030" hasStroke="0"/>
  925. </BACKGROUND>
  926. <GROUPCOMPONENT name="screenGroup" id="3d078232c622c691" memberName="screenGroup"
  927. virtualName="" explicitFocusOrder="0" pos="16 8 32M 100" outlinecol="ffffffff"
  928. textcol="ffffffff" title="Screen"/>
  929. <LABEL name="displayLabel" id="47dccaa09248b15c" memberName="displayLabel"
  930. virtualName="" explicitFocusOrder="0" pos="32 32 80 24" textCol="ffffffff"
  931. edTextCol="ff000000" edBkgCol="0" labelText="Display #:" editableSingleClick="0"
  932. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  933. fontsize="15" bold="0" italic="0" justification="33"/>
  934. <SLIDER name="displaySlider" id="2250b6248ed28fc6" memberName="displaySlider"
  935. virtualName="" explicitFocusOrder="1" pos="120 32 64 24" min="0"
  936. max="10" int="0" style="IncDecButtons" textBoxPos="TextBoxLeft"
  937. textBoxEditable="1" textBoxWidth="24" textBoxHeight="20" skewFactor="1"/>
  938. <LABEL name="screenLabel" id="68a950dbc12277f7" memberName="screenLabel"
  939. virtualName="" explicitFocusOrder="0" pos="32 64 80 24" textCol="ffffffff"
  940. edTextCol="ff000000" edBkgCol="0" labelText="Screen #:" editableSingleClick="0"
  941. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  942. fontsize="15" bold="0" italic="0" justification="33"/>
  943. <SLIDER name="screenSlider" id="74df429060e256ad" memberName="screenSlider"
  944. virtualName="" explicitFocusOrder="2" pos="120 64 64 24" min="0"
  945. max="10" int="0" style="IncDecButtons" textBoxPos="TextBoxLeft"
  946. textBoxEditable="1" textBoxWidth="24" textBoxHeight="20" skewFactor="1"/>
  947. <LABEL name="screenWidthLabel" id="1a8ebe15d549d3a2" memberName="screenWidthLabel"
  948. virtualName="" explicitFocusOrder="0" pos="200 32 64 24" textCol="ffffffff"
  949. edTextCol="ff000000" edBkgCol="0" labelText="Width:" editableSingleClick="0"
  950. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  951. fontsize="15" bold="0" italic="0" justification="33"/>
  952. <TEXTEDITOR name="screenWidthText" id="179a2a3eef834bff" memberName="screenWidthText"
  953. virtualName="" explicitFocusOrder="3" pos="264 32 48 24" initialText=""
  954. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="0"
  955. caret="1" popupmenu="1"/>
  956. <LABEL name="screenHeightLabel" id="778bbd3e6ce86ce2" memberName="screenHeightLabel"
  957. virtualName="" explicitFocusOrder="0" pos="200 64 64 24" textCol="ffffffff"
  958. edTextCol="ff000000" edBkgCol="0" labelText="Height:" editableSingleClick="0"
  959. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  960. fontsize="15" bold="0" italic="0" justification="33"/>
  961. <TEXTEDITOR name="screenHeightText" id="fabfd798833e0222" memberName="screenHeightText"
  962. virtualName="" explicitFocusOrder="4" pos="264 64 48 24" initialText=""
  963. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="0"
  964. caret="1" popupmenu="1"/>
  965. <LABEL name="xOffsetLabel" id="fca78bd84d691a86" memberName="xOffsetLabel"
  966. virtualName="" explicitFocusOrder="0" pos="326 32 64 24" textCol="ffffffff"
  967. edTextCol="ff000000" edBkgCol="0" labelText="Offset X:" editableSingleClick="0"
  968. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  969. fontsize="15" bold="0" italic="0" justification="33"/>
  970. <TEXTEDITOR name="xOffsetText" id="a370562e4f63e34" memberName="xOffsetText"
  971. virtualName="" explicitFocusOrder="5" pos="390 32 48 24" initialText=""
  972. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="1"
  973. caret="1" popupmenu="1"/>
  974. <LABEL name="yOffsetLabel" id="f2efae168df49c68" memberName="yOffsetLabel"
  975. virtualName="" explicitFocusOrder="0" pos="326 64 64 24" textCol="ffffffff"
  976. edTextCol="ff000000" edBkgCol="0" labelText="Offset Y:" editableSingleClick="0"
  977. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  978. fontsize="15" bold="0" italic="0" justification="33"/>
  979. <TEXTEDITOR name="yOffsetText" id="e4bb3613f81dc5f4" memberName="yOffsetText"
  980. virtualName="" explicitFocusOrder="6" pos="390 64 48 24" initialText=""
  981. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="1"
  982. caret="1" popupmenu="1"/>
  983. <GROUPCOMPONENT name="cameraGroup" id="5f4ffe47101cb73b" memberName="cameraGroup"
  984. virtualName="" explicitFocusOrder="0" pos="16 116 32M 64" outlinecol="ffffffff"
  985. textcol="ffffffff" title="Camera"/>
  986. <LABEL name="cameraDevLabel" id="b00161e3a7f27d06" memberName="cameraDevLabel"
  987. virtualName="" explicitFocusOrder="0" pos="32 140 80 24" textCol="ffffffff"
  988. edTextCol="ff000000" edBkgCol="0" labelText="Device:" editableSingleClick="0"
  989. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  990. fontsize="15" bold="0" italic="0" justification="33"/>
  991. <COMBOBOX name="cameraDevCombo" id="f143a9d8fad92dd2" memberName="cameraDevCombo"
  992. virtualName="" explicitFocusOrder="7" pos="120 140 200 24" editable="0"
  993. layout="33" items="" textWhenNonSelected="(no camera devices)"
  994. textWhenNoItems="(no camera devices)"/>
  995. <LABEL name="cameraResLabel" id="e2a00639ad344d6" memberName="cameraResLabel"
  996. virtualName="" explicitFocusOrder="0" pos="332 140 80 24" textCol="ffffffff"
  997. edTextCol="ff000000" edBkgCol="0" labelText="Resolution:" editableSingleClick="0"
  998. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  999. fontsize="15" bold="0" italic="0" justification="33"/>
  1000. <COMBOBOX name="cameraResCombo" id="bcc0c59e13c46f76" memberName="cameraResCombo"
  1001. virtualName="" explicitFocusOrder="8" pos="420 140 200 24" editable="0"
  1002. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1003. <GROUPCOMPONENT name="audioGroup" id="bd120721f1c416c8" memberName="audioGroup"
  1004. virtualName="" explicitFocusOrder="0" pos="16 188 32M 100" outlinecol="ffffffff"
  1005. textcol="ffffffff" title="Audio"/>
  1006. <LABEL name="audioApiLabel" id="70eaf09dd19cec91" memberName="audioApiLabel"
  1007. virtualName="" explicitFocusOrder="0" pos="32 212 64 24" textCol="ffffffff"
  1008. edTextCol="ff000000" edBkgCol="0" labelText="Interface:" editableSingleClick="0"
  1009. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1010. fontsize="15" bold="0" italic="0" justification="33"/>
  1011. <COMBOBOX name="audioApiCombo" id="1534dd6f247fe207" memberName="audioApiCombo"
  1012. virtualName="" explicitFocusOrder="9" pos="120 212 200 24" editable="0"
  1013. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1014. <LABEL name="audioDevLabel" id="12df9ce40ba72b7a" memberName="audioDevLabel"
  1015. virtualName="" explicitFocusOrder="0" pos="332 212 80 24" textCol="ffffffff"
  1016. edTextCol="ff000000" edBkgCol="0" labelText="Device:" editableSingleClick="0"
  1017. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1018. fontsize="15" bold="0" italic="0" justification="33"/>
  1019. <COMBOBOX name="audioDevCombo" id="899e83b4b547b630" memberName="audioDevCombo"
  1020. virtualName="" explicitFocusOrder="10" pos="420 212 200 24" editable="0"
  1021. layout="33" items="" textWhenNonSelected="(no audio devices)"
  1022. textWhenNoItems="(no audio devices)"/>
  1023. <LABEL name="audioCodecLabel" id="7994dcfae467506e" memberName="audioCodecLabel"
  1024. virtualName="" explicitFocusOrder="0" pos="33 248 80 24" textCol="ffffffff"
  1025. edTextCol="ff000000" edBkgCol="0" labelText="Codec:" editableSingleClick="0"
  1026. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1027. fontsize="15" bold="0" italic="0" justification="33"/>
  1028. <COMBOBOX name="audioCodecCombo" id="2a7a7ebbdd0e6d60" memberName="audioCodecCombo"
  1029. virtualName="" explicitFocusOrder="11" pos="121 248 96 24" editable="0"
  1030. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no devices)"/>
  1031. <LABEL name="nChannelsLabel" id="96c39fde349e5dd5" memberName="nChannelsLabel"
  1032. virtualName="" explicitFocusOrder="0" pos="232 248 80 24" textCol="ffffffff"
  1033. edTextCol="ff000000" edBkgCol="0" labelText="Channels:" editableSingleClick="0"
  1034. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1035. fontsize="15" bold="0" italic="0" justification="33"/>
  1036. <SLIDER name="nChannelsSlider" id="f465840b69633eb" memberName="nChannelsSlider"
  1037. virtualName="" explicitFocusOrder="12" pos="320 248 64 24" min="0"
  1038. max="10" int="0" style="IncDecButtons" textBoxPos="TextBoxLeft"
  1039. textBoxEditable="1" textBoxWidth="24" textBoxHeight="20" skewFactor="1"/>
  1040. <LABEL name="samplerateLabel" id="9744752cbe30d209" memberName="samplerateLabel"
  1041. virtualName="" explicitFocusOrder="0" pos="395 248 76 24" textCol="ffffffff"
  1042. edTextCol="ff000000" edBkgCol="0" labelText="Samplerate:" editableSingleClick="0"
  1043. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1044. fontsize="15" bold="0" italic="0" justification="33"/>
  1045. <COMBOBOX name="samplerateCombo" id="6adde69b5cba6e32" memberName="samplerateCombo"
  1046. virtualName="" explicitFocusOrder="13" pos="478 248 80 24" editable="0"
  1047. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1048. <LABEL name="audioBitrateLabel" id="166d559a6691cadc" memberName="audioBitrateLabel"
  1049. virtualName="" explicitFocusOrder="0" pos="574 248 64 24" textCol="ffffffff"
  1050. edTextCol="ff000000" edBkgCol="0" labelText="Bitrate:" editableSingleClick="0"
  1051. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1052. fontsize="15" bold="0" italic="0" justification="33"/>
  1053. <COMBOBOX name="audioBitrateCombo" id="7a1546dc1bcc36" memberName="audioBitrateCombo"
  1054. virtualName="" explicitFocusOrder="14" pos="640 248 80 24" editable="0"
  1055. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1056. <GROUPCOMPONENT name="textGroup" id="223402a4fb961517" memberName="textGroup"
  1057. virtualName="" explicitFocusOrder="0" pos="16 296 32M 64" outlinecol="ffffffff"
  1058. textcol="ffffffff" title="Text"/>
  1059. <LABEL name="motdLabel" id="e26a158d569b8f" memberName="motdLabel" virtualName=""
  1060. explicitFocusOrder="0" pos="32 320 80 24" textCol="ffffffff"
  1061. edTextCol="ff000000" edBkgCol="0" labelText="Message:" editableSingleClick="0"
  1062. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1063. fontsize="15" bold="0" italic="0" justification="33"/>
  1064. <TEXTEDITOR name="motdText" id="fb4f8a059431ce61" memberName="motdText" virtualName=""
  1065. explicitFocusOrder="15" pos="120 320 284 24" initialText="" multiline="0"
  1066. retKeyStartsLine="0" readonly="0" scrollbars="1" caret="1" popupmenu="1"/>
  1067. <LABEL name="textStyleLabel" id="3e58deec4ea2f148" memberName="textStyleLabel"
  1068. virtualName="" explicitFocusOrder="0" pos="420 320 52 24" textCol="ffffffff"
  1069. edTextCol="ff000000" edBkgCol="0" labelText="Style:" editableSingleClick="0"
  1070. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1071. fontsize="15" bold="0" italic="0" justification="33"/>
  1072. <COMBOBOX name="textStyleCombo" id="1d3707271064fb55" memberName="textStyleCombo"
  1073. virtualName="" explicitFocusOrder="16" pos="480 320 80 24" editable="0"
  1074. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1075. <LABEL name="textPosLabel" id="6dd629239c17c38b" memberName="textPosLabel"
  1076. virtualName="" explicitFocusOrder="0" pos="568 320 64 24" textCol="ffffffff"
  1077. edTextCol="ff000000" edBkgCol="0" labelText="Position:" editableSingleClick="0"
  1078. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1079. fontsize="15" bold="0" italic="0" justification="33"/>
  1080. <COMBOBOX name="textPosCombo" id="3074c311575e36ac" memberName="textPosCombo"
  1081. virtualName="" explicitFocusOrder="17" pos="640 320 80 24" editable="0"
  1082. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1083. <GROUPCOMPONENT name="interstitialGroup" id="21b5d7e16b61393b" memberName="interstitialGroup"
  1084. virtualName="" explicitFocusOrder="0" pos="18 368 32M 64" outlinecol="ffffffff"
  1085. textcol="ffffffff" title="Interstitial"/>
  1086. <LABEL name="locationLabel" id="d9e5b9eda1c0b4fe" memberName="locationLabel"
  1087. virtualName="" explicitFocusOrder="0" pos="34 392 80 24" textCol="ffffffff"
  1088. edTextCol="ff000000" edBkgCol="0" labelText="Location:" editableSingleClick="0"
  1089. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1090. fontsize="15" bold="0" italic="0" justification="33"/>
  1091. <TEXTEDITOR name="interstitialText" id="7634583caff4457b" memberName="interstitialText"
  1092. virtualName="" explicitFocusOrder="18" pos="122 392 486 24" initialText=""
  1093. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="1"
  1094. caret="1" popupmenu="1"/>
  1095. <TEXTBUTTON name="browseButton" id="b593253ef702db73" memberName="browseButton"
  1096. virtualName="" explicitFocusOrder="19" pos="640 392 80 24" buttonText="Browse"
  1097. connectedEdges="0" needsCallback="1" radioGroupId="0"/>
  1098. <GROUPCOMPONENT name="outputGroup" id="1fdfd2606ad4d79b" memberName="outputGroup"
  1099. virtualName="" explicitFocusOrder="0" pos="16 440 32M 100" outlinecol="ffffffff"
  1100. textcol="ffffffff" title="Output"/>
  1101. <LABEL name="outputStreamLabel" id="dac22e20ce0dd8e" memberName="outputStreamLabel"
  1102. virtualName="" explicitFocusOrder="0" pos="32 464 80 24" textCol="ffffffff"
  1103. edTextCol="ff000000" edBkgCol="0" labelText="Destination:" editableSingleClick="0"
  1104. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1105. fontsize="15" bold="0" italic="0" justification="33"/>
  1106. <COMBOBOX name="outputSinkCombo" id="12e0750a2c746a13" memberName="outputSinkCombo"
  1107. virtualName="" explicitFocusOrder="20" pos="120 464 64 24" editable="0"
  1108. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no devices)"/>
  1109. <LABEL name="outputWidthLabel" id="f42b11722ea56a92" memberName="outputWidthLabel"
  1110. virtualName="" explicitFocusOrder="0" pos="204 464 64 24" textCol="ffffffff"
  1111. edTextCol="ff000000" edBkgCol="0" labelText="Width:" editableSingleClick="0"
  1112. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1113. fontsize="15" bold="0" italic="0" justification="33"/>
  1114. <TEXTEDITOR name="outputWidthText" id="57d131f0667f6b73" memberName="outputWidthText"
  1115. virtualName="" explicitFocusOrder="21" pos="268 464 48 24" initialText=""
  1116. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="0"
  1117. caret="0" popupmenu="1"/>
  1118. <LABEL name="outputHeightLabel" id="786372012685b65a" memberName="outputHeightLabel"
  1119. virtualName="" explicitFocusOrder="0" pos="332 464 64 24" textCol="ffffffff"
  1120. edTextCol="ff000000" edBkgCol="0" labelText="Height:" editableSingleClick="0"
  1121. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1122. fontsize="15" bold="0" italic="0" justification="33"/>
  1123. <TEXTEDITOR name="outputHeightText" id="7e14834485ae7a91" memberName="outputHeightText"
  1124. virtualName="" explicitFocusOrder="22" pos="396 464 48 24" initialText=""
  1125. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="0"
  1126. caret="0" popupmenu="1"/>
  1127. <LABEL name="framerateLabel" id="45b2235a7a1f9614" memberName="framerateLabel"
  1128. virtualName="" explicitFocusOrder="0" pos="460 464 40 24" textCol="ffffffff"
  1129. edTextCol="ff000000" edBkgCol="0" labelText="FPS:" editableSingleClick="0"
  1130. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1131. fontsize="15" bold="0" italic="0" justification="33"/>
  1132. <COMBOBOX name="framerateCombo" id="2560e172b011e11c" memberName="framerateCombo"
  1133. virtualName="" explicitFocusOrder="23" pos="506 464 48 24" editable="0"
  1134. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1135. <LABEL name="bitrateLabel" id="bc6b3717e710f16c" memberName="bitrateLabel"
  1136. virtualName="" explicitFocusOrder="0" pos="572 464 64 24" textCol="ffffffff"
  1137. edTextCol="ff000000" edBkgCol="0" labelText="Bitrate:" editableSingleClick="0"
  1138. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1139. fontsize="15" bold="0" italic="0" justification="33"/>
  1140. <COMBOBOX name="videoBitrateCombo" id="54c30dff37473763" memberName="videoBitrateCombo"
  1141. virtualName="" explicitFocusOrder="24" pos="640 464 80 24" editable="0"
  1142. layout="33" items="" textWhenNonSelected="" textWhenNoItems="(no choices)"/>
  1143. <LABEL name="outputDestLabel" id="a1c19ea70cf15d1b" memberName="outputDestLabel"
  1144. virtualName="" explicitFocusOrder="0" pos="32 500 80 24" textCol="ffffffff"
  1145. edTextCol="ff000000" edBkgCol="0" labelText="Location:" editableSingleClick="0"
  1146. editableDoubleClick="0" focusDiscardsChanges="0" fontname="Default font"
  1147. fontsize="15" bold="0" italic="0" justification="33"/>
  1148. <TEXTEDITOR name="outputDestText" id="569abe636085fb4a" memberName="outputDestText"
  1149. virtualName="" explicitFocusOrder="25" pos="120 500 600 24" initialText=""
  1150. multiline="0" retKeyStartsLine="0" readonly="0" scrollbars="1"
  1151. caret="1" popupmenu="1"/>
  1152. </JUCER_COMPONENT>
  1153. END_JUCER_METADATA
  1154. */
  1155. #endif
  1156. //[EndFile] You can add extra defines here...
  1157. //[/EndFile]