12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- namespace Webmify {
- public abstract class EncodingProfile {
- public string size { get; protected set; }
- public string codec_names { get; protected set; }
- public double fps { get; protected set; }
- public EncodingProfile? alternative_to { get; set; }
- protected double get_low_framerate(double input_framerate) {
- if(input_framerate >= 50) {
- return input_framerate / 2;
- }
- return input_framerate;
- }
- public abstract string[] get_first_pass_command(string input_path, string output_path);
- public abstract string[] get_second_pass_command(string input_path, string output_path);
- public abstract string output_name();
- public abstract string version_label();
-
- public abstract bool suitable_for(VideoInfo info);
- public abstract void setup_for(VideoInfo info);
- }
- public static Invercargill.Enumerable<EncodingProfile> construct_profiles() {
- var vp9_720 = new Vp9Video720pProfile();
- var vp9_480 = new Vp9Video480pProfile();
- var vp9_360 = new Vp9Video360pProfile();
- var vp9_240 = new Vp9Video240pProfile();
- return Invercargill.Convert.ate(new EncodingProfile[] {
- new Vp9Video1080pHighFramerateProfile (),
- new Vp9Video1080pLowFramerateProfile (),
- vp9_720,
- vp9_480,
- vp9_360,
- vp9_240,
- });
- }
- }
|