/// <summary> /// Encoding Pass Controls /// <summary> public static void EncodingPassControls() { switch (VM.VideoView.Video_Codec_SelectedItem) { // -------------------------------------------------- // Video // -------------------------------------------------- // ------------------------- // VP8 // ------------------------- case "VP8": VP8.EncodingPass(); break; // ------------------------- // VP9 // ------------------------- case "VP9": VP9.EncodingPass(); break; // ------------------------- // x264 // ------------------------- case "x264": x264.EncodingPass(); break; // ------------------------- // x265 // ------------------------- case "x265": x265.EncodingPass(); break; // ------------------------- // AV1 // ------------------------- case "AV1": AV1.EncodingPass(); break; // ------------------------- // FFV1 // ------------------------- case "FFV1": FFV1.EncodingPass(); break; // ------------------------- // HuffYUV // ------------------------- case "HuffYUV": HuffYUV.EncodingPass(); break; // ------------------------- // Theora // ------------------------- case "Theora": Theora.EncodingPass(); break; // ------------------------- // MPEG-2 // ------------------------- case "MPEG-2": MPEG_2.EncodingPass(); break; // ------------------------- // MPEG-4 // ------------------------- case "MPEG-4": MPEG_4.EncodingPass(); break; // -------------------------------------------------- // Image // -------------------------------------------------- // ------------------------- // JPEG // ------------------------- case "JPEG": JPEG.EncodingPass(); break; // ------------------------- // PNG // ------------------------- case "PNG": PNG.EncodingPass(); break; // ------------------------- // WebP // ------------------------- case "WebP": WebP.EncodingPass(); break; // -------------------------------------------------- // Other // -------------------------------------------------- // ------------------------- // Copy // ------------------------- case "Copy": VideoCopy.EncodingPass(); break; // ------------------------- // None // ------------------------- case "None": VideoNone.EncodingPass(); break; } // ------------------------- // CRF TextBox // ------------------------- if (VM.VideoView.Video_Quality_SelectedItem == "Custom") { // Disable if (VM.VideoView.Video_Pass_SelectedItem == "CRF") { VM.VideoView.Video_CRF_IsEnabled = true; } // Enable else if (VM.VideoView.Video_Pass_SelectedItem == "1 Pass" || VM.VideoView.Video_Pass_SelectedItem == "2 Pass" || VM.VideoView.Video_Pass_SelectedItem == "auto") { VM.VideoView.Video_CRF_IsEnabled = false; } } }
/// <summary> /// Encoding Pass Controls /// <summary> public static void EncodingPassControls() { // -------------------------------------------------- // Video // -------------------------------------------------- // ------------------------- // VP8 // ------------------------- if (VM.VideoView.Video_Codec_SelectedItem == "VP8") { VP8.EncodingPass(); } // ------------------------- // VP9 // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "VP9") { VP9.EncodingPass(); } // ------------------------- // x264 // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "x264") { x264.EncodingPass(); } // ------------------------- // x265 // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "x265") { x265.EncodingPass(); } // ------------------------- // AV1 // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "AV1") { AV1.EncodingPass(); } // ------------------------- // FFV1 // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "FFV1") { FFV1.EncodingPass(); } // ------------------------- // HuffYUV // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "HuffYUV") { HuffYUV.EncodingPass(); } // ------------------------- // Theora // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "Theora") { Theora.EncodingPass(); } // ------------------------- // MPEG-2 // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "MPEG-2") { MPEG_2.EncodingPass(); } // ------------------------- // MPEG-4 // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "MPEG-4") { MPEG_4.EncodingPass(); } // -------------------------------------------------- // Image // -------------------------------------------------- // ------------------------- // JPEG // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "JPEG") { JPEG.EncodingPass(); } // ------------------------- // PNG // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "PNG") { PNG.EncodingPass(); } // ------------------------- // WebP // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "WebP") { WebP.EncodingPass(); } // -------------------------------------------------- // Other // -------------------------------------------------- // ------------------------- // Copy // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "Copy") { VideoCopy.EncodingPass(); } // ------------------------- // None // ------------------------- else if (VM.VideoView.Video_Codec_SelectedItem == "None") { VideoNone.EncodingPass(); } // ------------------------- // CRF TextBox // ------------------------- if (VM.VideoView.Video_Quality_SelectedItem == "Custom") { // Disable if (VM.VideoView.Video_Pass_SelectedItem == "CRF") { VM.VideoView.Video_CRF_IsEnabled = true; } // Enable else if (VM.VideoView.Video_Pass_SelectedItem == "1 Pass" || VM.VideoView.Video_Pass_SelectedItem == "2 Pass" || VM.VideoView.Video_Pass_SelectedItem == "auto") { VM.VideoView.Video_CRF_IsEnabled = false; } } }