public AdaptiveMuxWindow(MainForm mainForm) : base(mainForm) { InitializeComponent(); jobUtil = new JobUtil(mainForm); muxProvider = mainForm.MuxProvider; audioTracks[0].Filter = VideoUtil.GenerateCombinedFilter(ContainerManager.AudioTypes.ValuesArray); subtitleTracks[0].Filter = VideoUtil.GenerateCombinedFilter(ContainerManager.SubtitleTypes.ValuesArray); vInput.Filter = VideoUtil.GenerateCombinedFilter(ContainerManager.VideoTypes.ValuesArray); cbContainer.Visible = true; lbContainer.Visible = true; this.cbContainer.SelectedIndexChanged += new System.EventHandler(this.cbContainer_SelectedIndexChanged); }
public baseMuxWindow(MainForm mainForm) : this() { this.mainForm = mainForm; this.settings = mainForm.Settings; muxProvider = mainForm.MuxProvider; cbType.Items.Add("Standard"); cbType.Items.AddRange(muxProvider.GetSupportedDevices().ToArray()); cbType.SelectedIndex = 0; }
public OneClickWindow(MainForm mainForm, JobUtil jobUtil, VideoEncoderProvider vProv, AudioEncoderProvider aProv) { this.mainForm = mainForm; vUtil = new VideoUtil(mainForm); this.muxProvider = mainForm.MuxProvider; acceptableContainerTypes = muxProvider.GetSupportedContainers().ToArray(); InitializeComponent(); initTabs(); videoProfile.Manager = mainForm.Profiles; initAudioHandler(); avsProfile.Manager = mainForm.Profiles; initOneClickHandler(); audioTrack1.StandardItems = audioTrack2.StandardItems = new object[] { "None" }; audioTrack1.SelectedIndex = audioTrack2.SelectedIndex = 0; //if containerFormat has not yet been set by the oneclick profile, add supported containers if (containerFormat.Items.Count == 0) { containerFormat.Items.AddRange(muxProvider.GetSupportedContainers().ToArray()); this.containerFormat.SelectedIndex = 0; } //add device type if (devicetype.Items.Count == 0) { devicetype.Items.Add("Standard"); devicetype.Items.AddRange(muxProvider.GetSupportedDevices().ToArray()); this.devicetype.SelectedIndex = 0; } showAdvancedOptions_CheckedChanged(null, null); }
/// <summary> /// default constructor /// initializes all the GUI components, initializes the internal objects and makes a default selection for all the GUI dropdowns /// In addition, all the jobs and profiles are being loaded from the harddisk /// </summary> public void constructMeGUIInfo() { muxProvider = new MuxProvider(this); this.codecs = new CodecManager(); this.path = System.Windows.Forms.Application.StartupPath; this.jobUtil = new JobUtil(this); this.settings = new MeGUISettings(); addPackages(); this.profileManager = new ProfileManager(this.path); this.profileManager.LoadProfiles(); this.mediaFileFactory = new MediaFileFactory(this); this.loadSettings(); this.dialogManager = new DialogManager(this); }
public AutoEncodeWindow(VideoStream videoStream, List<AudioJob> audioStreams, MainForm mainForm, bool prerender, VideoInfo vInfo) : this() { this.vInfo = vInfo; mainForm.Log.Add(log); this.videoStream = videoStream; this.audioStreams = audioStreams; this.prerender = prerender; this.mainForm = mainForm; jobUtil = new JobUtil(mainForm); vUtil = new VideoUtil(mainForm); muxProvider = mainForm.MuxProvider; container.Items.AddRange(muxProvider.GetSupportedContainers().ToArray()); splitting.MinimumFileSize = new FileSize(Unit.MB, 1); }
public Calculator(MainForm mainForm) : this() { this.mainForm = mainForm; this.muxProvider = mainForm.MuxProvider; this.videoCodec.Items.AddRange(CodecManager.VideoEncoderTypes.ValuesArray); videoCodec.SelectedItem = CodecManager.VideoEncoderTypes["x264"]; this.containerFormat.Items.AddRange(muxProvider.GetSupportedContainers().ToArray()); containerFormat.SelectedItem = ContainerType.MKV; // set complexity from settings this.complexity.Minimum = 0; this.complexity.Maximum = 100; this.complexity.Value = (mainForm.Settings.MinComplexity + mainForm.Settings.MaxComplexity) / 2; this.complexity.Minimum = mainForm.Settings.MinComplexity; this.complexity.Maximum = mainForm.Settings.MaxComplexity; // wire the input boxes to auto-select text on focus AddAutoSelectHandler(this); // set focus of calculate by this.averageBitrateRadio.Click += (s, args) => projectedBitrate.Focus(); this.bppRadio.Click += (s, args) => bpp.Focus(); this.qEstRadio.Click += (s, args) => qest.Focus(); this.fileSizeRadio.Click += (s, args) => targetSize.Focus(); // smart focus for audio and extras (try to fix render bug w/ scrollbar) this.audioExtraFlow.ControlRemoved += (s, args) => { int idx = (int)args.Control.Tag; if (idx > 0) audioExtraFlow.Controls[idx - 1].Focus(); TagIndexes(); }; this.audioExtraFlow.ControlAdded += (s, args) => { args.Control.Focus(); TagIndexes(); }; }