Beispiel #1
0
        private void btOutputConfigure_Click(object sender, RoutedEventArgs e)
        {
            switch (cbOutputFormat.SelectedIndex)
            {
            case 0:
            {
                if (aviSettingsDialog == null)
                {
                    aviSettingsDialog = new AVISettingsDialog(VideoCapture1.Video_Codecs.ToArray(), VideoCapture1.Audio_Codecs.ToArray());
                }

                aviSettingsDialog.ShowDialog(this);

                break;
            }

            case 1:
            {
                if (wmvSettingsDialog == null)
                {
                    wmvSettingsDialog = new WMVSettingsDialog(VideoCapture1);
                }

                wmvSettingsDialog.WMA = false;
                wmvSettingsDialog.ShowDialog(this);

                break;
            }

            case 2:
            {
                if (mp4V10SettingsDialog == null)
                {
                    mp4V10SettingsDialog = new MP4v10SettingsDialog();
                }

                mp4V10SettingsDialog.ShowDialog(this);

                break;
            }

            case 3:
            {
                if (mp4v11SettingsDialog == null)
                {
                    mp4v11SettingsDialog = new MFSettingsDialog(MFSettingsDialogMode.MP4v11);
                }

                mp4v11SettingsDialog.ShowDialog(this);

                break;
            }

            case 4:
            {
                if (gifSettingsDialog == null)
                {
                    gifSettingsDialog = new GIFSettingsDialog();
                }

                gifSettingsDialog.ShowDialog(this);

                break;
            }

            case 5:
            {
                if (mpegTSSettingsDialog == null)
                {
                    mpegTSSettingsDialog = new MFSettingsDialog(MFSettingsDialogMode.MPEGTS);
                }

                mpegTSSettingsDialog.ShowDialog(this);

                break;
            }

            case 6:
            {
                if (movSettingsDialog == null)
                {
                    movSettingsDialog = new MFSettingsDialog(MFSettingsDialogMode.MOV);
                }

                movSettingsDialog.ShowDialog(this);

                break;
            }
            }
        }
        private void btConfigure_Click(object sender, EventArgs e)
        {
            switch (cbOutputFormat.SelectedIndex)
            {
            case 0:
            {
                if (aviSettingsDialog == null)
                {
                    aviSettingsDialog = new AVISettingsDialog(
                        VideoEdit1.Video_Codecs.ToArray(),
                        VideoEdit1.Audio_Codecs.ToArray());
                }

                aviSettingsDialog.ShowDialog(this);

                break;
            }

            case 1:
            {
                if (aviSettingsDialog == null)
                {
                    aviSettingsDialog = new AVISettingsDialog(
                        VideoEdit1.Video_Codecs.ToArray(),
                        VideoEdit1.Audio_Codecs.ToArray());
                }

                aviSettingsDialog.ShowDialog(this);

                break;
            }

            case 2:
            {
                if (wmvSettingsDialog == null)
                {
                    wmvSettingsDialog = new WMVSettingsDialog(VideoEdit1);
                }

                wmvSettingsDialog.WMA = false;
                wmvSettingsDialog.ShowDialog(this);

                break;
            }

            case 3:
            {
                if (dvSettingsDialog == null)
                {
                    dvSettingsDialog = new DVSettingsDialog();
                }

                dvSettingsDialog.ShowDialog(this);

                break;
            }

            case 4:
            {
                if (webmSettingsDialog == null)
                {
                    webmSettingsDialog = new WebMSettingsDialog();
                }

                webmSettingsDialog.ShowDialog(this);

                break;
            }

            case 5:
            {
                if (ffmpegDLLSettingsDialog == null)
                {
                    ffmpegDLLSettingsDialog = new FFMPEGDLLSettingsDialog();
                }

                ffmpegDLLSettingsDialog.ShowDialog(this);

                break;
            }

            case 6:
            {
                if (ffmpegEXESettingsDialog == null)
                {
                    ffmpegEXESettingsDialog = new FFMPEGEXESettingsDialog();
                }

                ffmpegEXESettingsDialog.ShowDialog(this);

                break;
            }

            case 7:
            {
                if (mp4V10SettingsDialog == null)
                {
                    mp4V10SettingsDialog = new MP4v10SettingsDialog();
                }

                mp4V10SettingsDialog.ShowDialog(this);

                break;
            }

            case 8:
            {
                if (mp4v11SettingsDialog == null)
                {
                    mp4v11SettingsDialog = new MFSettingsDialog(MFSettingsDialogMode.MP4v11);
                }

                mp4v11SettingsDialog.ShowDialog(this);

                break;
            }

            case 9:
            {
                if (gifSettingsDialog == null)
                {
                    gifSettingsDialog = new GIFSettingsDialog();
                }

                gifSettingsDialog.ShowDialog(this);

                break;
            }

            case 10:
            {
                if (mp4V10SettingsDialog == null)
                {
                    mp4V10SettingsDialog = new MP4v10SettingsDialog();
                }

                mp4V10SettingsDialog.ShowDialog(this);

                break;
            }
            }
        }
        private void BtOutputConfigure_Click(object sender, RoutedEventArgs e)
        {
            switch (cbOutputFormat.SelectedIndex)
            {
            case 0:
            {
                if (aviSettingsDialog == null)
                {
                    aviSettingsDialog = new AVISettingsDialog(VideoCapture1.Video_Codecs.ToArray(), VideoCapture1.Audio_Codecs.ToArray());
                }

                aviSettingsDialog.ShowDialog(this);

                break;
            }

            case 1:
            {
                if (aviSettingsDialog == null)
                {
                    aviSettingsDialog = new AVISettingsDialog(VideoCapture1.Video_Codecs.ToArray(), VideoCapture1.Audio_Codecs.ToArray());
                }

                aviSettingsDialog.ShowDialog(this);

                break;
            }

            case 2:
            {
                if (wmvSettingsDialog == null)
                {
                    wmvSettingsDialog = new WMVSettingsDialog(VideoCapture1);
                }

                wmvSettingsDialog.WMA = false;
                wmvSettingsDialog.ShowDialog(this);

                break;
            }

            case 3:
            {
                if (dvSettingsDialog == null)
                {
                    dvSettingsDialog = new DVSettingsDialog();
                }

                dvSettingsDialog.ShowDialog(this);

                break;
            }

            case 4:
            {
                MessageBox.Show("No settings available for selected output format.");

                break;
            }

            case 5:
            {
                if (webmSettingsDialog == null)
                {
                    webmSettingsDialog = new WebMSettingsDialog();
                }

                webmSettingsDialog.ShowDialog(this);

                break;
            }

            case 6:
            {
                if (ffmpegDLLSettingsDialog == null)
                {
                    ffmpegDLLSettingsDialog = new FFMPEGDLLSettingsDialog();
                }

                ffmpegDLLSettingsDialog.ShowDialog(this);

                break;
            }

            case 7:
            {
                if (ffmpegEXESettingsDialog == null)
                {
                    ffmpegEXESettingsDialog = new FFMPEGEXESettingsDialog();
                }

                ffmpegEXESettingsDialog.ShowDialog(this);

                break;
            }

            case 8:
            {
                if (mp4V10SettingsDialog == null)
                {
                    mp4V10SettingsDialog = new MP4v10SettingsDialog();
                }

                mp4V10SettingsDialog.ShowDialog(this);

                break;
            }

            case 9:
            {
                if (mp4v11SettingsDialog == null)
                {
                    mp4v11SettingsDialog = new MFSettingsDialog(MFSettingsDialogMode.MP4v11);
                }

                mp4v11SettingsDialog.ShowDialog(this);

                break;
            }

            case 10:
            {
                if (gifSettingsDialog == null)
                {
                    gifSettingsDialog = new GIFSettingsDialog();
                }

                gifSettingsDialog.ShowDialog(this);

                break;
            }

            case 11:
            {
                if (mp4V10SettingsDialog == null)
                {
                    mp4V10SettingsDialog = new MP4v10SettingsDialog();
                }

                mp4V10SettingsDialog.ShowDialog(this);

                break;
            }

            case 12:
            {
                if (mpegTSSettingsDialog == null)
                {
                    mpegTSSettingsDialog = new MFSettingsDialog(MFSettingsDialogMode.MPEGTS);
                }

                mpegTSSettingsDialog.ShowDialog(this);

                break;
            }

            case 13:
            {
                if (movSettingsDialog == null)
                {
                    movSettingsDialog = new MFSettingsDialog(MFSettingsDialogMode.MOV);
                }

                movSettingsDialog.ShowDialog(this);

                break;
            }
            }
        }