Exemplo n.º 1
0
        private void InsertAudioChannels()
        {
            ReportStart(_cache.AudioChannels, "Audio Channels");

            var currentProgress = 0;

            foreach (var item in _cache.AudioChannels)
            {
                var entity = new Entity.tAudioChannels()
                {
                    Channels = item,
                };

                _context.tAudioChannels.Add(entity);

                AudioChannels.Add(item, entity);

                IncreaseCurrent(ref currentProgress);
            }

            ReportFinish();
        }
Exemplo n.º 2
0
        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);
                }
            }
        }