public static Process CreateFFmpeg(FFmpegArguments args) { return(Process.Start(new ProcessStartInfo { FileName = "ffmpeg", Arguments = args.CommandLineArguments, UseShellExecute = false, RedirectStandardOutput = args.PipedOutput, RedirectStandardInput = args.PipedInput, RedirectStandardError = true, })); }
public TeamspeakService(DiscordSocketClient client, IConfigService config) : base(config) { this.client = client; this.config = config; ffmpegArguments = new FFmpegArguments().WithOutputFormat("s16le").WithPipedOutput(); Enabled = bool.Parse(File.ReadAllText(stateFile)); if (Enabled) { _ = Enable(); } }
public AlarmService(SchedulerService scheduler, DiscordSocketClient client, Random random, IConfigService config) : base(config) { this.client = client; this.random = random; this.scheduler = scheduler; ffmpegArguments = new FFmpegArguments().WithOutputFormat("s16le").WithPipedOutput(); DateTime dateTime = DateTime.Parse("6:00am"); scheduler.ScheduleRecurringTask(dateTime, "AlarmRescheduler", RescheduleAlarms); //Schedule the alarms in case bot is restarted mid school day RescheduleAlarms(null); }
public MusicService() { youtube = new YoutubeClient(); fFmpegArguments = new FFmpegArguments().WithInputFile("test").WithPipedOutput().WithOutputFormat("s16le"); }