Esempio n. 1
0
        private void customPreset(String inputFile, String outputDirectory, customPreset cspre)
        {
            String parameters = "-y -i " + '"' + inputFile + '"' + " -b:v " + cspre.vbitrate + " -s " + cspre.resolution + " -vcodec " + cspre.vcodec + " -acodec " + cspre.acodec + " " + '"' + outputDirectory + "\\P2.mp4" + '"';

            Console.WriteLine(parameters);
            doConvert(parameters);
        }
Esempio n. 2
0
        private void presetCreator()
        {
            customPre = new customPreset();
            var comboBoxes = this.Controls
                             .OfType <ComboBox>()
                             .Where(x => x.Name.StartsWith("comboBox"));

            foreach (var cmbBox in comboBoxes)
            {
                if (cmbBox.Name.Equals("comboBoxAudioCodecsCollection"))
                {
                    customPre.acodec = comboBoxAudioCodecsCollection.SelectedItem.ToString();
                }

                if (cmbBox.Name.Equals("comboBoxAudioBitrateCollection"))
                {
                    customPre.abitrate = comboBoxAudioBitrateCollection.SelectedItem.ToString();
                }

                if (cmbBox.Name.Equals("comboBoxVideoCodecsCollection"))
                {
                    customPre.vcodec = comboBoxVideoCodecsCollection.SelectedItem.ToString();
                }

                if (cmbBox.Name.Equals("comboBoxVideoBitratesCollection"))
                {
                    customPre.vbitrate = comboBoxVideoBitratesCollection.SelectedItem.ToString();
                }

                if (cmbBox.Name.Equals("comboBoxVideoResolutionCollection"))
                {
                    customPre.resolution = comboBoxVideoResolutionCollection.SelectedItem.ToString();
                }
            }
        }
Esempio n. 3
0
        public void detectPreset(String inputFile, String outputDirectory, String preset, ffmpegTEI formt, int frameCount, customPreset testPreset)
        {
            this.formRef         = formt;
            this.totalFrameCount = frameCount;

            switch (preset)
            {
            case "Audio Only":
                AudioOnly(inputFile, outputDirectory);
                break;

            case "Video Only":
                VideoOnly(inputFile, outputDirectory);
                break;

            case "PSP":
                PSP(inputFile, outputDirectory);
                break;

            case "Custom":
                customPreset(inputFile, outputDirectory, testPreset);
                break;

            default:
                MessageBox.Show("Incorrect preset selected!");
                break;
            }
        }
Esempio n. 4
0
 private void ffmpegTEI_Load(object sender, EventArgs e)
 {
     customPre = new customPreset();
     ff        = new ffPresets(this);
 }