Пример #1
0
		public Mp3Settings(AudioConversionElement audioConversion)
		{
			var channels = audioConversion.Channel;

			if (channels > 2)
			{
				channels = 2;
			}

			CodecName = "libmp3lame";
			FileNameExtension = "mp3";
			BitRate = audioConversion.BitRate;
			Channels = channels;
			Frequency = audioConversion.Frequency;

			AllowedMetaData = new List<string>()
			               	{
			               		"Title",
			               		"Author", 
			               		"Album", 
			               		"Year", 
			               		"Comment", 
			               		"Track", 
			               		"Genre",
			               	};
		}
Пример #2
0
		public AacSettings(AudioConversionElement audioConversion)
		{
			CodecName = "libvo_aacenc";
			FileNameExtension = "aac";
			BitRate = audioConversion.BitRate;
			Channels = audioConversion.Channel;
			Frequency = audioConversion.Frequency;
			Options = AllFixedOptions;

			AllowedMetaData = new List<string>
			               	{
			               		"Title",
								"Artist",
								"AlbumArtist",
			               		"Album",
			               		"Grouping",
			               		"Composer",
			               		"Year",
								"Track",
			               		"Comment",
								"Genre",
								"Copyright",
								"Description",
								"Synopsis",
								"Show",
								"EpisodeId",
								"Network",
								"Lyrics",
			               	};
		}
        private static void AddAudioConversionSetting(ProjectElement project)
        {
            var configurationProperty = project.GetConfigurationProperty(AudioConversionConfiguration.Instance.ElementCollectionSettingName);
            var commandElementCollection = project.GetElementCollection<AudioConversionElementCollection>(configurationProperty);

            var element = new AudioConversionElement
            {
                Name = "AudioConversionElement",
                OutPutPath = @"c:\",
            };

            commandElementCollection.Add(element);
        }
Пример #4
0
		public VorbisSettings(AudioConversionElement audioConversion)
		{
			CodecName = "libvorbis";
			FileNameExtension = "oga";
			BitRate = audioConversion.BitRate;
			Channels = audioConversion.Channel;
			Frequency = audioConversion.Frequency;

			AllowedMetaData = new List<string>()
			               	{
			               		"Title",
			               		"Author", 
			               		"Album", 
			               		"Year", 
			               		"Comment", 
			               		"Track", 
			               		"Genre",
			               	};
		}