private void InsertAudioFormats() { ReportStart(_cache.AudioFormat, "Audio Format"); var currentProgress = 0; foreach (var item in _cache.AudioFormat) { var entity = new Entity.tAudioFormat() { Format = item, }; _context.tAudioFormat.Add(entity); AudioFormat.Add(item, entity); IncreaseCurrent(ref currentProgress); } ReportFinish(); }
private void FillAudioHashes(IEnumerable <Profiler.AudioTrack> audioTracks) { if (audioTracks == null) { return; } var valid = audioTracks.Where(IsNotNull); foreach (var audioTrack in valid) { AudioContent.Add(audioTrack.Content); if (!string.IsNullOrEmpty(audioTrack.Format)) { AudioFormat.Add(audioTrack.Format); } if (!string.IsNullOrEmpty(audioTrack.Channels)) { AudioChannels.Add(audioTrack.Channels); } } }