Пример #1
0
        /// <summary>
        /// Erzeugt eine neue Einspieleinheit.
        /// </summary>
        /// <param name="filter">Der zugehörige Filter.</param>
        /// <param name="name">Der Name dieser Einheit.</param>
        /// <param name="type">Die Beschreibung des Datenstromformates.</param>
        public ESInjector(TSFilter filter, string name, MediaType type)
            : base(1000, 8 * 1024)
        {
            // Remember
            m_MajorType = type.MajorType;
            m_MinorType = type.SubType;
            m_Filter    = filter;

            // Create the pin
            m_Pin = new LivePin(filter, name, type);

            // Connect sink to injector base
            SetSink(m_Pin.Receive);

            // Create stream
            CreateConsumer();
        }
Пример #2
0
        /// <summary>
        /// Beendet die Nutzung dieser Instanz endgültig.
        /// </summary>
        public override void Dispose()
        {
            // Stop receiving data
            using (_StreamConsumer stream = m_Stream)
                m_Stream = null;

            // Forward to base
            base.Dispose();

            // Forward to pin
            if (null != m_Pin)
            {
                // Forward
                m_Pin.Dispose();

                // Forget
                m_Pin = null;
            }
        }
Пример #3
0
        /// <summary>
        /// Beendet die Nutzung dieser Instanz endgültig.
        /// </summary>
        public override void Dispose()
        {
            // Stop receiving data
            using (_StreamConsumer stream = m_Stream)
                m_Stream = null;

            // Forward to base
            base.Dispose();

            // Forward to pin
            if (null != m_Pin)
            {
                // Forward
                m_Pin.Dispose();

                // Forget
                m_Pin = null;
            }
        }
Пример #4
0
        /// <summary>
        /// Erzeugt eine neue Einspieleinheit.
        /// </summary>
        /// <param name="filter">Der zugehörige Filter.</param>
        /// <param name="name">Der Name dieser Einheit.</param>
        /// <param name="type">Die Beschreibung des Datenstromformates.</param>
        public ESInjector( TSFilter filter, string name, MediaType type )
            : base( 1000, 8 * 1024 )
        {
            // Remember
            m_MajorType = type.MajorType;
            m_MinorType = type.SubType;
            m_Filter = filter;

            // Create the pin
            m_Pin = new LivePin( filter, name, type );

            // Connect sink to injector base
            SetSink( m_Pin.Receive );

            // Create stream
            CreateConsumer();
        }